Hi there
Im trying to write up a code where two txt files are being compared to each other. One text files has the answer like "TFTTFFT" and the other txt files has the result including id like "1234 TT-FFT" The crazy part is that for each correct answer, the student gets 4 points and for every incorrect answer, the student gets -1 and for every no answer, which in this case is represented by a dash(-), the student gets zero. How do i go about writing up a code for this? ANy help will be very much appreciated. I dont necessarly need some one to code this for me as i have pretty much done the opening of files and stroing them in appropriate varaibles. Just a feed back on how to go about doing this would be nice. THank you in advance.
vbenthu
0
Newbie Poster
Recommended Answers
Jump to PostOne file has a line like "TFTTFFT" which I presume are the correct answers (true/false) for seven questions. Does the second file contain multiple lines (one for each student) in the format "#### " followed by the same number of "T", "F" or "-" entries as there are in the …
All 3 Replies
Reverend Jim
4,780
Hi, I'm Jim, one of DaniWeb's moderators.
Moderator
Featured Poster
TnTinMN
418
Practically a Master Poster
vbenthu
0
Newbie Poster
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.