Class 11 Computer Science Chapter 6 File Handling Quiz 12 (60 MCQs)

Quiz Instructions

Select an option to see the correct answer instantly.

1. F = open("test.txt", "a") f.write("Hello World!")
2. The ..... files are not in human readable form.
3. How do you read data from a file using Fileinputstream in Java?
4. Each line in a CSV file is called a .....
5. How do you open a file for both reading and writing in C++?
6. Which of the following modes should be used when opening a file for writing?
7. The ..... text files which store the text in the same form as typed.
8. Which statement is CORRECT about the 'READ' mode?
9. Apa nilai default dari parameter delimiter yang digunakan pada fungsi pandas.read ..... csv() dan numpy.loadtxt()?
10. Which of the following is a valid way to define a pointer to a structure?
11. What happens if a program does not properly close a file after writing to it?
12. How can you pass a variable number of arguments to a function?
13. Apa yang akan ditampilkan jika fgets berhasil membaca baris dari file?
14. What is the purpose of the with statement when working with files?
15. This function connects the file written on the disk with file object
16. What is the code to open a file named as My ..... Data for reading data from it?
17. The file pointer is reset to the start of the file using:
18. We don't need to be careful with the 'w' mode as it will not overwrite into the file if it already exists.
19. What is the difference between 'r' and 'rb' file modes?
20. What is the description of the following file mode 'w+'
21. File formats are specified in the file name
22. Which mode is used to write to a file (overwriting if exists)?
23. Which library is used in Python for binary file serialization?
24. Which function is used to unpickle data from a binary file?
25. What is the root folder on Windows typically referred to as?
26. Which function is used to check if the end of a file has been reached?
27. How can you ensure data is read one line at a time from a file?
28. 'w' mode creates a new file if one did not exist at the specified location.
29. Apa yang akan terjadi jika Anda mencoba membaca dari file yang tidak ada?
30. How do you append text to a file?
31. What is the purpose of the program in Program 13.2?
32. Which type of file format is used to store tabular data like in a spreadsheet?
33. How do you create a Fileinputstream object in Java?
34. Select the statement to open a file named MYDATA.txt in read and write mode. Let the file object name be myfile.
35. Which method is used to write text to a file in Python?
36. What method is used to read a file line by line?
37. What is the function of the 'getline' method in C++ file handling?
38. What method would you use to write a list of strings to a file?
39. In seek () you can move the file pointer in forward direction with the help of ..... values
40. What are the different modes of opening a file using Fileoutputstream in Java?
41. ..... helps in storing information.
42. Fungsi apa yang digunakan untuk menulis data terformat ke file?
43. What function is used to write a list of dictionaries to a csv file in Python?
44. What does the '.write' method do?
45. Which memory is volatile memory?
46. A 1D array declaration can be written as:
47. What is the function "r" in file handling
48. The following is an example of what type of error?prnt("Hello World")
49. The default delimiter of the CSV file is .....
50. Which of the following option is the correct Python statement to read and display the first 10 characters of a text file "Notes.txt" ?
51. What is the result of calling add ..... two(10, -5)?
52. What will happen if you try to open a non-existent file in "r" mode?
53. Differentiate between binary, CSV, and text files in Python.
54. What does setting a Boolean variable to false indicate in file handling?
55. Which of the following packages contain classes and interfaces used for input & output operations of file?
56. What does calloc() do in C programming?
57. Which method is used to close the Stream?
58. Ravi opened the file myfile.txt in append mode. In this file the file object/file handle will be at the .....
59. What is the purpose of the 'data dependency' in the context of file handling?
60. Which of the following operator is used for negation?