CBSE Class 12 Computer Science Question 9 of 136

Data File Handling — Question 9

Back to all questions
9
Question

Question 9

Assertion (A): Text file stores information in the ASCII or Unicode format/characters.

Reasoning (R): In a text file, there is no delimiter for a line.

  1. Both A and R are true and R is the correct explanation of A.
  2. Both A and R are true but R is not the correct explanation of A.
  3. A is true but R is false.
  4. A is false but R is true.
Answer

A is true but R is false.

Explanation
In a text file, information is stored in the form of ASCII or Unicode characters. Each line in a text file is terminated by a special character known as End of Line (EOL), and by default, this EOL character is the newline character (\n), which serves as the delimiter for lines in text files.