Python Programming Unit 4 – File Operations & Regular Expressions: important questions for AKTU
Unit 4 (File Operations & Regular Expressions) questions that AKTU repeats most often. This unit carries about 19 marks per paper. Start with the repeated questions, then the most asked topics.
Most repeated Unit 4 questions
- What are file operations in Python? Explain the different modes used while opening a file. (7 marks, 2026, File Reading) – also asked in 2022, 2023, 2025
- Explain file handling modes in Python. (7 marks, 2025, File Reading) – also asked in 2023, 2026
- What is the purpose of the seek() method in file handling? Demonstrate a program that copies content from one file to another. (7 marks, 2026, File Pointer Manipulation) – also asked in 2025
Most important Unit 4 topic
- File Reading (Unit 4: File Operations & Regular Expressions) – asked 11 times in 2020, 2022, 2023, 2025, 2026
- File Writing (Unit 4: File Operations & Regular Expressions) – asked 9 times in 2021, 2023, 2024, 2025, 2026
- Exceptions & Error Handling (Unit 4: File Operations & Regular Expressions) – asked 8 times in 2020, 2021, 2022, 2023, 2025
Most asked Unit 4 topics
- File Reading – asked 11 times
- File Writing – asked 9 times
- Exceptions & Error Handling – asked 8 times
More Unit 4 previous year questions
- What is a file pointer in Python? (2 marks, 2026, File Pointer Manipulation)
- What are read() and readline() functions in file handling? (2 marks, 2026, File Reading)
- Describe file writing functions: write(), writelines(). Write a program to write student records to a file. (7 marks, 2026, File Writing)
- Explain manipulating file pointer using seek(). Write a program to read last n lines from a file. (7 marks, 2026, File Pointer Manipulation)
- Describe regular expressions using re module. Write a program to find all digits in a string. (7 marks, 2026, Regular Expressions)
Unit 4 syllabus topics
- File Reading
- File Writing
- File Pointer Manipulation
- Regular Expressions
- Exceptions & Error Handling