Saturday, October 10, 2009

OOP344 Assignment progress

My program has successfully passed all tests except for 2:

Test 9.14:
Complaint about curpos. It says that curpos should be at 20, mine returned 19. But fieldlen of 20 is passed to io_edit. Shouldn't curpos be 1 less than fieldlen?
Anyone else having this problem?

Test 9.23:
Complaint about curpos and offset. It seems that curpos and offset should not be moved in this function. But IsTextEditor is set to false we should be able to move curpos and offset as long as the string returned is the orginal one and not the modified one.
Any thoughts on that?

1 comment:

  1. Hi Verity, I'll explain about what's troubling you.

    For Test 9.14, it's testing that when you press the right key, that the cursor should be after the last character of the str and doesn't move more spaces after.

    For Test 9.23, it wants you to set the offset and the curpos to the original value that were given when io_edit was first called.

    Hope this helps.

    ReplyDelete