Programming in Python with Full Stack Development - Exam Questions
1. Introduction to Python Programming
3-4 Marks:
- Explain data types in Python with examples.
- Difference between list, set, tuple, and dictionary.
- Write a program using loops and conditionals.
5-7 Marks:
- Write a Python program to demonstrate string operations (slicing, concatenation, find, etc.).
- Compare mutable and immutable data types in Python.
- Write a Python program to store and access values in a dictionary.
8 Marks:
- Explain control flow in Python with a program using if-else, for, and while loops.
- Create a Python program using all data types (list, tuple, set, dict) with built-in functions.
2. Functions, OOPs, and File Handling
3-4 Marks:
- Define a function with arguments and return values.
- Explain the difference between *args and **kwargs.
5-7 Marks:
- Write a program to demonstrate class, object, and inheritance.
- Explain exception handling with a try-except block.
- Demonstrate file reading and writing using Python.
8 Marks:
- Create a class with all four OOP concepts (Encapsulation, Abstraction, Inheritance, Polymorphism).
- File handling with exception management using a real-world example.
3. Modules and Packages, IDE & GIT
Programming in Python with Full Stack Development - Exam Questions
3-4 Marks:
- How to create and use modules in Python?
- What is the use of PyCharm IDE in development?
5-7 Marks:
- Explain how to use third-party libraries in Python with pip.
- Demonstrate Git integration with PyCharm.
8 Marks:
- CRUD operation using Python and MySQL/MongoDB with example.
- Explain how to manage a project using modules, packages, and Git.
4. Flask Framework
3-4 Marks:
- What is Flask? How is it different from Django?
- Explain routing in Flask with example.
5-7 Marks:
- Create a simple Flask app with form submission and template rendering.
- Connect Flask to MySQL and perform basic insert operation.
8 Marks:
- Develop a full Flask app that uses HTML template, POST method, form data, and error handling.
5. Django Framework
3-4 Marks:
- What is Django? Explain its features.
- Explain the role of the manage.py file.
5-7 Marks:
- Create a Django project with one app and explain folder structure.
Programming in Python with Full Stack Development - Exam Questions
- Demonstrate working of static and media files in Django.
8 Marks:
- Build a Django CRUD app using model, form, and template.
6. RESTful APIs
3-4 Marks:
- What is REST architecture?
- Differentiate between GET and POST methods.
5-7 Marks:
- Design a RESTful API using Flask or Django Rest Framework for a user database.
- Explain the use of Postman and cURL for testing APIs.
8 Marks:
- Build a secure REST API using Flask and implement CRUD with status codes and error handling.