Computer Science (AS & A Level) · Oct / Nov 2024 · Paper 21 · Question 3
9618
As printed in the paper
The question as text
An algorithm will output the last three lines from a text file Result.txt The lines need to be output in the same order as they appear in the file. Assume: • Three variables LineX, LineY and LineZ will store the three lines. These are of type string and all three variables have been initialised to an empty string. • The file exists and contains at least three lines.
Read automatically from the paper; the printed page above is exact.
Show the answer and mark scheme
3(a)[4]
3(b)[1]
3(c)[4]
Make a free account to save your answers and see your weak topics and ask the AI why a wrong answer is wrong.

