Viva prep · Real questions · Student experiences Enroll in Bootcamp

Proctor workspace

Proctor Level3_42

Share your experience Add your viva experience here
182 Questions
16 Sets
0 Topics
15 Reviews
Tips for this examiner: Know your project very well, he'll tell you to change functionality, so first explain how you are going to proceed and then go ahead

Student reviews

Sheet response MAD1

He is great, He tests if you know what you wrote.
Be confident and explain what you know, accept that some little things you maybe wrong, so you'll look over it. He appreciates logic.

Questions remembered
  1. -> download file from portal, demo - of specific features he requests
  2. -> app.py & routes - specific line explanations (whichever he requests)
  3. -> model.py - Backref meaning, how it's defined in python
  4. -> How do you implement upload an image and store in the app
  5. -> Put vs patch
  6. -> Specific feature demo, like Unassign a trek from staff.
  7. -> coding: Implement route such that trek ID is given, have to display all the users who booked.
Pratyaksh Pandey MAD1

He is the best proctor i've ever met, just go through the code and ask yourself regarding the edge cases, and done, he helps you wherever you stuck in the viva, but he wants the answers, even if you have partial correct, he will consider it done

Questions remembered
  1. ADMIN LOGIN
  2. ADD A TREK
  3. DELETE A TREK
  4. EDIT A TREK
  5. GO BACK TO LOGIN PAGE
  6. CHANGE THE BACKGROUND COLOR
  7. CHANGE THE NAVBAR POSITION
  8. GO TO CODE OPEN MODELS.PY
  9. WHAT IS BACKREF, BACKPOPULATES, PRIMARY KEY, FOREIGN KEY
  10. WHAT IS JUNCTION TABLE
  11. MAKE A NEW COLUMN TO THE REGISTER PAGE
  12. MAKE CONFIRM PASSWORD
  13. CONNECT CONFIRM PASSWORD TO BACKEND
  14. WRITE A ROUTE TO FETCH USERID WITH HELP OF TREKID
  15. IS ASSIGNING A STAFF IMPORTANT OR OPTIONAL
  16. IF YOUR DONT WRITE RETURN RENDER_TEMPLATE WHAT WILL HAPPEN
  17. WHAT IS HTTP METHODS
  18. WHAT IS TEMPLATE INHERITANCE
  19. WHAT IS JINJA, AND WHY DID YOU USE JINJA
  20. WHAT IS BOOTSTRAP WHERE HAVE YOU USED
  21. HOW MUCH AI HAVE YOU USED
n MAD1

He is very calm, may ask some out of the box questions but its ok if you dont know them word by word, the understanding of the code is crucial, know your routes, know your models, just go thru every like of your code before giving viva.

Questions remembered
  1. level 2
  2. -Asked me to show id and then install the project from viva portal and give a demo
  3. -He quickly took the demo, checked form validation, told me change the url and tell aksed what happens, asked simple question about pages, asked me to create a job, so he ended the demo in about 15 mins and then we came to code
  4. -he asked several questions
  5. 1-what is orm
  6. 2-differnece between back populates and back ref, why i used back populates
  7. 3-asked me to show the models then said why i used only one file for models and routes and all(i took theory and project together so its reasonable enough to not know the file system at start nor does it matter in this project)
  8. 4- asked if i wanted to make the project from start then how like i distribute the file(models, routes and app.start)
  9. 5-asked why i use uselist in model(for one-one relation), then asked what if we want to relation be to one-many(simply remove the uselist)
  10. 6-how the relationships in models work(thru foreign key we make relationships)
  11. 7- asked me what specific like numbers does
  12. 8-post,put,patch
  13. 9-authenticaton and authorization and where have i used them in my code
  14. 10- some more route questions(easy)
  15. code coding question - he asked me to add a confirm password feature in register page(easy- first in html file then validate in backend)
  16. then asked what if we return nothing in the backend for this if statement
  17. asked some port questions, like what status codes will it give, asked asked for what status code d i know(named all the codes that i knew)
  18. and the viva ended, basically he will test your understanding of the code, mainly focused on app.py, didn't ask any question regarding html or css or chart.js that i used
  19. Then i asked how was my viva and he said that he was impressed, i have a good understanding of my code and i answered his every question.
Anisha Singh MAD1

He was kind and friendly. He was mainly interested in knowing whether the student has completed the project independently and know their own project whatever they have used and if used the AI or some tool so just know what you are using and what that line of code is doing.

Questions remembered
  1. He asked whether you have used the AI or not in completing this project I said I used then he asked how and where did you used? 2.He didn't asked for demonstration but rather asked to login into company dashboard and then create a new drive, and show how any student apply in that drive so I did the same.
  2. After that as I created a new student so he asked me to go on to the registration page back and asked me to add the same email, username which I just created for the previous question so I did that but could not be able to take that registration as I defined unique username and email so it gave a flash (user exists)so he said ok
  3. Then he asked me to go to the company dashboard again and asked to see in the application section of that drive to view if that students application is there or not.
  4. Then he asked that in that table in company_dashboard where I stored the ongoing drive details, add another column for the No. Of Application for each drives I started but forget how to count the application so he asked first of to use Google for syntax but I was trying so he told to use( | length) the. It worked.
  5. Then he asked to go to code and explain how I connected my flask app to database so I showed all the steps
  6. Then he asked what is use of ORM
  7. Then he asked to explain Authorization and Authentication in my code
  8. Then he asked from the login route, what is the http method when we are displaying the flash message
  9. Then he asked go to any other route for authorisation I used manually checking like for each route(if user_email is in session and whether the role is assigned to access the page details) for this he asked whether we can replace it with any simpler alternative I told for this we can use the flask-login and using decorator function @login-required then he said ok
  10. Then he asked difference between POST, PUT, PATCH
  11. Then he asked whether I used bootstrap I said yes then he asked how so I showed the link which I used in base.html
  12. He asked what is bootstrap why I used this
  13. Then he asked as I have used the link so if there is weak internet or not internet connection so still this bootstrap will work or not, app will work or not. I said yes but then he said are you sure so I said I didn't tried it yet so he said ok
  14. Then he asked go to company_dashboard on browser -> create drive option and he asked if I want to add another field for location or any other field so what will happen to other previously created drives
  15. Then he asked have you heard of catching I said no
  16. Then he said have you heard of application put scaling(something like this, but didn't remember the exact term he used) so I said I heard of scaling then he asked what is that so I explained scaling and its two types vertical and horizontal where they are used in which architecture for what and then he said ok that's all from my side
Bharath K MAD1

Proctor was good and helped me to understand the question he asked by commenting in the GMeet chatbox. And I can able to answer well. Some questions I don't answer properly but sir understood. Level2 Viva went well. So, be thorough with your app.py coding in your project and answer well. Just look for common questions in previous term viva questions and go through your project coding which will be asked in Level2 viva. Be patient and don't get nervous in Level2 as it is important.

Questions remembered
  1. Show me the ID card.
  2. Download the file from VivaPortal.
  3. Show me the demo.
  4. Have you use any AI for your project ?
  5. Asked the 2 questions based on coding like you explain what does line no ___(any number) do.
  6. Asked to add the confirmed password code in student registration page.
  7. What is POST, PUT and PATCH ?
  8. Exception Handling.
  9. What is authentication and authorization ?
  10. What is ORM ?
  11. Why do you use Bootstrap in your project ?
s MAD1

Know your code very well like be ready to explain your kinda theoretically too. Sir is very calm and chill and polite. He is a young guy so i felt like he was more understanding. Even if u don't know the exact answer, say something related to it atleast. He is a very patient man is what i personally felt. I couldnt run my app because of net issues for like 15min but he was calm and that made me feel at ease.

Questions remembered
  1. He said good morning and asked me how i was doing then i told him i was nervous but he was like don't be
  2. 1.demonstrate the app
  3. 2.he did not ask anything beyond the code i have written
  4. 3.he is interested in knowing what i wrote in the code and asked me why i wrote this that etc
  5. 4.asked me about models,about orm,how relationship is formed, bootstrap, any api used, if i know about exception handling, have i used it in my code, authentication vs authorization, what is isinstance, current_user etc from my code, working of app flow
  6. As for code change: asked me to add delete button for drive created by company but i got an error so he was like lets move onto next question and continued to ask questions related to my code (i almost created the button but had some error maybe thats why he told me to move on)
Sheet response MAD1

look into the questions he's asked previously, he's pretty chill if you don't know certain things as long as your basics are clear you're good, you got this!

Questions remembered
  1. checksum and oppe setup
  2. demo (checking functionality)
  3. where is authentication and authorization implemented
  4. how relations are defined between models (in code)
  5. (code): make sure no doctor with existing bookings gets deleted
  6. exception handling and HTTP codes
  7. where is bootstrapping in the code and where and how is it used
  8. if i am familiar with javascript, i told him i wasn't but the charts in my project were js which i created using AI and he said using llms for extra functionalities is fine :)
  9. what is your understanding of scaling
  10. are you interested in app dev the viva lasted for less than 30 minutes, he said i did well and had a good understanding of the flow of code in my project and my basics were clear, all in all pretty straightforward questions, might point to certain lines in the code or ask questions like "where is the current user getting initialized in the code"
Sheet response MAD1

Go through the previous questions in the form he is chill and nice guy accept it if u don't know the ans but get good understanding about ur code

Questions remembered
  1. 1.demo
  2. 2.mainly he focused on doctor's
  3. 3.y used bootstrap and show me the code how u used it
  4. 4.about Authorization and authentication and its implementation
  5. 5.template inheritance
  6. 6.write a code so that admin cannot delete a doctor if he has active appointment using appointment id and doctor if(I have appointment table)
  7. 7 .about reln between appointment and doctors,patient
Krishna Kumari MAD1

The proctor is really calm and nice, he just focuses on the project and ask relevant questions, doesn't go for theory much.
The proctor really just wants to check if the student is clear with the basics of app, for the rest he does help with writing code, i was nervous while editing the code so he did explain me what I should be doing and why is it necessary so it was really nice of him, so yes just be thorough with your basics and code that's enough to convince him, my viva ended in like 30 mins where the first 10 mins was all about setting up mobile, downloading app etc.

Questions remembered
  1. Level 2 viva :
  2. - Asked me to set up my camera, download project, checked id card as well and asked me to run my app
  3. - started with the demo but he himself started mentioning what he wants to see further so went with that, He majorly checked creating doctors and booking appointments giving availablity etc.
  4. - asked a bit about models like why have I used orm, why user mixin, just basic questions over random code he could see
  5. - same for routes, he specifically asked for doctor delete route and asked me to make a change so that if a doctor has upcoming appointment, admin gets a warning message
  6. - asked what is scaling, how would I go for large scaling apps
  7. - in models, asked for relationship between appointments, doctor and patient
  8. - also asked why did I have extensions.py (i was getting a circular import problem in my models.py and app.py that's why I had that so I explained the same)
naam jaanke kya karoge MAD1

keep calm he also helped you in code if you stuck just go through the question get ready to face practical questions instead of direct theory questions

Questions remembered
  1. Level-2
  2. show id
  3. demo(has asked do this try this and this means he check s the functionality in the demo only he wants)
  4. then asked about the route he pointed out the line number to explain its usage
  5. how database is created how it is connected to your app
  6. asked about relationships
  7. how you implemented authorization in code
  8. DOM
  9. Bootstrap how used and why
  10. scaling(not directly but with scenario what if multiple user try to your app)
  11. code written
  12. exception handling in one route
  13. on doctors registration page add confirm password then validate in route
  14. give scenario what and how you handle the situation if we want to add city to the doctor field how you would approach
Shiva Ramakrishna MAD1

Be practical with your code, cover edge cases and if you hadn't done them, mention them beforehand itself

Questions remembered
  1. Viva 2 Asked me to show the ID card first and then asked me to download the code from the website and run it Then showed the demo, the proctor asked for some functionalities mainly CRUD and some edge test cases. Was asking a lot of questions as I was giving the demo like(Also I was explaining some of the things while I explaining the demo alongside code)
  2. model part of your code - relationship between tables, cascading
  3. Sessions - where is the data stored
  4. Frameworks used
  5. Template inheritance
  6. CSS and bootstrapping
  7. Authorization Vs Authentication
  8. APIs
  9. creating a route for a new page which displays the occupied spots in a particular lot
  10. ORM
  11. JavaScript ( I have used some) - asked about DOM
  12. how do you scale your application ( scale up Vs scale down)
Neha MAD1

He's nice ,patient ,gave time to think and (he doesn't focus on theory much basic simple question)
He asked practical questions mostly
Use headphones

Questions remembered
  1. L3_42
  2. questions:
  3. What's orm
  4. How db getting created
  5. Explain models
  6. Jinja why it's used
  7. Bootstrap,how we import it ,uses
  8. Authorization
  9. Authentication
  10. How relationships are defined
  11. Explain relationship in your db
  12. Cascade
  13. Code change:
  14. Asked me to add confirm password field
  15. Make changes in edit parking lot route
  16. Also asked me if this my field of interest (I said no doing it for project only)
  17. Lasted for roughly 50 mins
Rathin MAD1

Just stay calm and honest… He’s going to ask you a lot of technical questions about how you did this. The viva lasted about 45 minutes, so make sure to review your routing.py.

Questions remembered
  1. He asked me a lot of coding questions.
  2. He made me write code, including routes.
  3. Asked about ORM (Object-Relational Mapping).
  4. Asked me to write code to enforce an alphanumeric password and throw an error for basic passwords like "1234".
  5. Asked about sessions and their purpose.
  6. Focused more on practical implementation rather than theory.
errorboy MAD1

Tip for level 1:
1. Don't be scared, be confident.
2. If you don't know any answer then answer something which is related to that question.
3. If you don't know anything about the question then just say, sorry sir/mam I can't recall it now.
4. Level 1 viva is simple you just need to give your demo properly.
5. Focus on database more in level 1 viva.
6. Ask for feedback before leaving the meet.

Questions remembered
  1. Level 1:
  2. Download the project from portal.
  3. Demo
  4. How you implemented month's wise number of quizzes attempted
  5. How you are deleting all chapters and it's related quizzes in your database
  6. Difference between Restful get and Patch ( basically difference) Level 2:
  7. Show the id card and download the project from portal and run checksum file.
  8. Demo
  9. How app.py work (like the application workflow)
  10. Questions on database (like how cascading work)
  11. Difference between authentication and authorization?
  12. questions about ports (like 302, 402 etc..)
  13. Difference between Get, Push.
  14. How you will scale your website basically scalability question.
  15. Change Navbar color.
  16. Modify date of the quiz to only take present or future date.
  17. Why you didn't use an API
Shrikkumar MAD1

Know your project very well, he'll tell you to change functionality, so first explain how you are going to proceed and then go ahead

Questions remembered
  1. Authentication and Authorization
  2. Cloud Services
  3. Horizontal Scaling and Vertical Scaling
  4. What is session and where it gets stored
  5. How do you handle runtime errors/ Have you heard about exceptions
  6. What should you change in order to manage thousands of requests in a single machine

Approved viva sets

  1. 1
    -> download file from portal, demo - of specific features he requests
    Times asked 1
    Official solution

    SimpleExaminer portal wala submitted ZIP chahta hai. Local extra changes mat dikhana.

    Suggested flow1) Portal ZIP download
    2) Extract
    3) venv + pip install -r requirements.txt
    4) flask run / python app.py

  2. 2
    -> app.py & routes - specific line explanations (whichever he requests)
    Times asked 1
    Official solution

    SimplePehle 1-line definition, phir apne MAD1 project mein file dikhao, phir chhota example.

    Suggested flow1) Concept kya hai?
    2) Mere code mein kahan?
    3) Example / demo
    4) Edge case

    Example

    # related file: models.py / routes / template
    # formula: request → check/auth → DB → render/redirect

    Viva tipExact line yaad nahi to honestly related part dikhao. Bluff mat karo.

  3. 3
    -> model.py - Backref meaning, how it's defined in python
    Times asked 1
    Official solution

    Simplebackref reverse attribute auto banata hai. back_populates dono sides explicitly naam dete ho — clearer.

    Example

    # backref
    spots = db.relationship('Spot', backref='lot')
    # spot.lot available
    
    # back_populates
    spots = db.relationship('Spot', back_populates='lot')
    # Spot.lot = db.relationship('Lot', back_populates='spots')
  4. 4
    -> How do you implement upload an image and store in the app
    Times asked 1
    Official solution

    SimpleCode explain formula: input kya aaya → auth/validation → DB change → response/UI.

    Viva tipFunction signature + 3-4 important lines + edge case.

  5. 5
    -> Put vs patch
    Times asked 1
    Official solution

    SimplePOST naya janam (har baar naya id). PUT poori photo replace. PATCH sticker chipkao.

    POST create, not idempotent. PUT full update, idempotent. PATCH partial.

    POST ki jagah PUT se REST semantics toot. GET typically no body.

    CRUD map: POST create, GET read, PUT/PATCH update, DELETE delete.

    Pehle 1-line definition, phir related MAD2 layer (Vue SFC / Flask route / models.py / tasks.py / Redis).

    4-line formula: input kahan se aaya, auth/validation kaunsa, DB ya cache ya Celery, kya return.

    Related mix mat karo — cache ≠ Celery, authentication ≠ authorization, v-if ≠ v-show, Beat ≠ Worker. Follow-up ke liye ek difference ready rakho.

    Example

    POST /api/venues
    PUT  /api/venues/1   {all fields}
    PATCH /api/venues/1 {only name}

    Project example: POST /api/venues create. PUT /venues/1 saari fields. PATCH sirf name.

  6. 6
    -> Specific feature demo, like Unassign a trek from staff.
    Times asked 1
    Official solution

    SimpleDemo script pehle se practice: 5–7 min, Admin + User roles, saare mandatory features.

    Suggested flow1) Register/login user
    2) Admin login — CRUD
    3) Approval/blacklist
    4) Booking/apply + edge case
    5) Search
    6) Logout

    Viva tipBolte-bolte dikhao. Code tab kholna jab poochhein.

  7. 7
    -> coding: Implement route such that trek ID is given, have to display all the users who booked.
    Times asked 1
    Official solution

    SimpleProject overview: problem → roles → main entities → key flows (register, book, admin approve).

    Viva tip1 minute elevator pitch ready rakho, phir demo.

Advice: He is great, He tests if you know what you wrote. Be confident and explain what you know, accept that some little things you maybe wrong, so you'll look over it. He appreciates logic.
  1. 1
    ADMIN LOGIN
    Times asked 1
    Official solution

    SimpleLogin flow pehle poochta hai "tu kaun hai?", token milne ke baad har API pe wohi proof dikhate ho.

    Authentication step: Vue form email + password JSON POST karta hai. Flask user dhoondhta hai, check_password_hash se prove karta hai ki tum genuine ho. Galat 401. Sahi pe JWT + role milta hai — yeh session/token hai.

    Vue localStorage (ya cookie) mein token rakhta hai, dashboard pe router.push. Aage ki har fetch header: Authorization: Bearer <token>. @jwt_required identity check (authentication). @roles_required('admin') permission check (authorization) — logged in ho, lekin allowed nahi to 403.

    Validation alag cheez hai: empty email, password 8+ — form sahi bhara hai ya nahi. Woh identity prove nahi karta.

    Logout = client token delete + login page. Server blacklist optional. Password response JSON mein kabhi mat bhejo.

    Example

    # Authentication
    @app.route('/api/login', methods=['POST'])
    def login():
        u = User.query.filter_by(email=data['email']).first()
        if not u or not check_password_hash(u.password, data['password']):
            return jsonify(msg='bad'), 401
        return jsonify(token=create_access_token(u.id), role=u.role)
    
    # baad ki APIs
    # Authorization: Bearer <token>
    if current_user.role != 'admin':
        abort(403)

    Project example: Login.vue POST /api/login → token LS → interceptor. Student token se admin route = 403. Empty form = validation, galat password = 401.

    Viva tipNetwork tab mein password body dikhega localhost pe — prod HTTPS. Response mein hash/password echo mat karo.

  2. 2
    ADD A TREK
    Times asked 1
    Official solution

    SimpleProject overview: problem → roles → main entities → key flows (register, book, admin approve).

    Viva tip1 minute elevator pitch ready rakho, phir demo.

  3. 3
    DELETE A TREK
    Times asked 1
    Official solution

    SimpleProject overview: problem → roles → main entities → key flows (register, book, admin approve).

    Viva tip1 minute elevator pitch ready rakho, phir demo.

  4. 4
    EDIT A TREK
    Times asked 1
    Official solution

    SimpleProject overview: problem → roles → main entities → key flows (register, book, admin approve).

    Viva tip1 minute elevator pitch ready rakho, phir demo.

  5. 5
    GO BACK TO LOGIN PAGE
    Times asked 1
    Official solution

    SimplePehle 1-line definition, phir apne MAD1 project mein file dikhao, phir chhota example.

    Suggested flow1) Concept kya hai?
    2) Mere code mein kahan?
    3) Example / demo
    4) Edge case

    Example

    # related file: models.py / routes / template
    # formula: request → check/auth → DB → render/redirect

    Viva tipExact line yaad nahi to honestly related part dikhao. Bluff mat karo.

  6. 6
    GO TO CODE OPEN MODELS.PY
    Times asked 1
    Official solution

    Simplemodels.py = har table ki class: columns, PK/FK, relationships. Yeh Model layer hai.

    Suggested flow1) Classes list karo
    2) Har table ka kaam 1 line
    3) Relationships (1-M / M-M)
    4) Constraints (unique, nullable)

    Example

    class Lot(db.Model):
        id = db.Column(db.Integer, primary_key=True)
        name = db.Column(db.String(80), nullable=False)
        spots = db.relationship('Spot', backref='lot', lazy=True)
  7. 7
    WHAT IS BACKREF, BACKPOPULATES, PRIMARY KEY, FOREIGN KEY
    Times asked 1
    Official solution

    SimplePrimary key row ka unique identity — usually id Integer autoincrement.

    Example

    id = db.Column(db.Integer, primary_key=True)
  8. 8
    MAKE A NEW COLUMN TO THE REGISTER PAGE
    Times asked 1
    Official solution

    SimpleDemo script pehle se practice: 5–7 min, Admin + User roles, saare mandatory features.

    Suggested flow1) Register/login user
    2) Admin login — CRUD
    3) Approval/blacklist
    4) Booking/apply + edge case
    5) Search
    6) Logout

    Viva tipBolte-bolte dikhao. Code tab kholna jab poochhein.

  9. 9
    MAKE CONFIRM PASSWORD
    Times asked 1
    Official solution

    SimpleLive UI change: relevant CSS/HTML template kholo — color, margin, flex, bootstrap class. Save + hard refresh.

    Example

    /* button red */
    .btn-primary { background: red; }
    
    /* center navbar item */
    .navbar { justify-content: center; }

    Viva tipDevTools se pehle try, phir file mein permanent change.

  10. 10
    CONNECT CONFIRM PASSWORD TO BACKEND
    Times asked 1
    Official solution

    SimplePehle 1-line definition, phir apne MAD1 project mein file dikhao, phir chhota example.

    Suggested flow1) Concept kya hai?
    2) Mere code mein kahan?
    3) Example / demo
    4) Edge case

    Example

    # related file: models.py / routes / template
    # formula: request → check/auth → DB → render/redirect

    Viva tipExact line yaad nahi to honestly related part dikhao. Bluff mat karo.

  11. 11
    WRITE A ROUTE TO FETCH USERID WITH HELP OF TREKID
    Times asked 1
    Official solution

    SimpleLive Flask coding: chhota route likho, save, browser/curl se test. Syntax error terminal mein padho.

    Example

    @app.route('/ping')
    def ping():
        return jsonify(ok=True)
    
    @app.route('/even/<int:n>')
    def even(n):
        return 'even' if n % 2 == 0 else 'odd'
  12. 12
    IS ASSIGNING A STAFF IMPORTANT OR OPTIONAL
    Times asked 1
    Official solution

    SimplePehle 1-line definition, phir apne MAD1 project mein file dikhao, phir chhota example.

    Suggested flow1) Concept kya hai?
    2) Mere code mein kahan?
    3) Example / demo
    4) Edge case

    Example

    # related file: models.py / routes / template
    # formula: request → check/auth → DB → render/redirect

    Viva tipExact line yaad nahi to honestly related part dikhao. Bluff mat karo.

  13. 13
    IF YOUR DONT WRITE RETURN RENDER_TEMPLATE WHAT WILL HAPPEN
    Times asked 1
    Official solution

    Simplerender_template Jinja HTML file ko data deke final HTML banata hai.

    Example

    return render_template('dashboard.html', user=user, lots=lots)
  14. 14
    WHAT IS HTTP METHODS
    Times asked 1
    Official solution

    SimpleHTTP verbs REST ke tools. Methods HTTP ke hain, REST unhe convention se use karta hai.

    GET read cacheable. POST create payload. PUT replace. PATCH patch. DELETE remove.

    GET exists bina REST ke bhi — browser address bar.

    HTTP verbs + status REST ki zabaan. GET read, POST create, PUT replace, PATCH partial, DELETE remove. GET typically no body.

    Status: 200 OK, 201 created, 202 accepted (Celery task), 400 bad input, 401 no/bad token, 403 role nahi, 404 missing, 409 conflict (double book), 500 server.

    AJAX/fetch page reload nahi. SPA poori isi pe. Postman se bina Vue ke API prove karo — examiner pasand.

    Example

    GET /api/venues
    POST /api/venues
    PUT /api/venues/1
    DELETE /api/venues/1

    Project example: resources.py methods list. Postman 4-5 calls.

    Viva tipGET typically no body (cacheable). POST/PUT/PATCH haan payload. PUT idempotent, POST nahi.

  15. 15
    WHAT IS BOOTSTRAP WHERE HAVE YOU USED
    Times asked 1
    Official solution

    SimpleBootstrap CSS framework — grid, navbar, buttons jaldi. CDN ya downloaded files.

  16. 16
    HOW MUCH AI HAVE YOU USED
    Times asked 1
    Official solution

    SimpleCode explain formula: input kya aaya → auth/validation → DB change → response/UI.

    Viva tipFunction signature + 3-4 important lines + edge case.

Advice: He is the best proctor i've ever met, just go through the code and ask yourself regarding the edge cases, and done, he helps you wherever you stuck in the viva, but he wants the answers, even if you have partial correct, he will consider it done
  1. 1
    -Asked me to show id and then install the project from viva portal and give a demo
    Times asked 1
    Official solution

    SimpleCamera pe clearly college/IITM ID dikhao — naam aur photo match hone chahiye.

    Viva tipPehle se ID haath mein rakho, glare mat aane do. Iske baad GitHub + project run.

  2. 2
    -he asked several questions
    Times asked 1
    Official solution

    SimpleViva wrap-up hai. Short thanks + confirm submission ZIP latest hai.

  3. 3
    2-differnece between back populates and back ref, why i used back populates
    Times asked 1
    Official solution

    Simplebackref reverse attribute auto banata hai. back_populates dono sides explicitly naam dete ho — clearer.

    Example

    # backref
    spots = db.relationship('Spot', backref='lot')
    # spot.lot available
    
    # back_populates
    spots = db.relationship('Spot', back_populates='lot')
    # Spot.lot = db.relationship('Lot', back_populates='spots')
  4. 4
    3-asked me to show the models then said why i used only one file for models and routes and all(i took theory and project together so its reasonable enough to not know the file system at start nor does it matter in this project)
    Times asked 1
    Official solution

    SimpleTheory = concepts: ORM, MVC, auth vs authz, Jinja inheritance, sessions. 1-line def + project example.

  5. 5
    4- asked if i wanted to make the project from start then how like i distribute the file(models, routes and app.start)
    Times asked 1
    Official solution

    Simplemodels.py = har table ki class: columns, PK/FK, relationships. Yeh Model layer hai.

    Suggested flow1) Classes list karo
    2) Har table ka kaam 1 line
    3) Relationships (1-M / M-M)
    4) Constraints (unique, nullable)

    Example

    class Lot(db.Model):
        id = db.Column(db.Integer, primary_key=True)
        name = db.Column(db.String(80), nullable=False)
        spots = db.relationship('Spot', backref='lot', lazy=True)
  6. 6
    5-asked why i use uselist in model(for one-one relation), then asked what if we want to relation be to one-many(simply remove the uselist)
    Times asked 1
    Official solution

    Simpleuselist=False relationship ko list nahi, single object banata hai — one-to-one / many-to-one scalar.

    Example

    profile = db.relationship('Profile', uselist=False, backref='user')
    # user.profile → Profile obj, list nahi
  7. 7
    6-how the relationships in models work(thru foreign key we make relationships)
    Times asked 1
    Official solution

    Simpledb.relationship se object graph: lot.spots, booking.user. backref reverse side auto deta hai.

    Example

    spots = db.relationship('Spot', backref='lot', cascade='all, delete-orphan')
  8. 8
    7- asked me what specific like numbers does
    Times asked 1
    Official solution

    SimplePehle 1-line definition, phir apne MAD1 project mein file dikhao, phir chhota example.

    Suggested flow1) Concept kya hai?
    2) Mere code mein kahan?
    3) Example / demo
    4) Edge case

    Example

    # related file: models.py / routes / template
    # formula: request → check/auth → DB → render/redirect

    Viva tipExact line yaad nahi to honestly related part dikhao. Bluff mat karo.

  9. 9
    9-authenticaton and authorization and where have i used them in my code
    Times asked 1
    Official solution

    SimpleAuthentication: tu kaun hai? (login). Authorization: tujhe permission hai? (role check).

    Example

    # auth
    if check_password_hash(user.password, pwd):
        session['user_id'] = user.id
    
    # authz
    if user.role != 'admin':
        abort(403)
  10. 10
    10- some more route questions(easy)
    Times asked 1
    Official solution

    SimpleViva wrap-up hai. Short thanks + confirm submission ZIP latest hai.

  11. 11
    then asked what if we return nothing in the backend for this if statement
    Times asked 1
    Official solution

    SimplePehle 1-line definition, phir apne MAD1 project mein file dikhao, phir chhota example.

    Suggested flow1) Concept kya hai?
    2) Mere code mein kahan?
    3) Example / demo
    4) Edge case

    Example

    # related file: models.py / routes / template
    # formula: request → check/auth → DB → render/redirect

    Viva tipExact line yaad nahi to honestly related part dikhao. Bluff mat karo.

  12. 12
    asked some port questions, like what status codes will it give, asked asked for what status code d i know(named all the codes that i knew)
    Times asked 1
    Official solution

    SimpleStatus code server ka result: 200 OK, 302 redirect, 400 bad input, 401/403 auth, 404 not found, 500 server error.

  13. 13
    and the viva ended, basically he will test your understanding of the code, mainly focused on app.py, didn't ask any question regarding html or css or chart.js that i used
    Times asked 1
    Official solution

    SimpleBootstrap CSS framework — grid, navbar, buttons jaldi. CDN ya downloaded files.

  14. 14
    Then i asked how was my viva and he said that he was impressed, i have a good understanding of my code and i answered his every question.
    Times asked 1
    Official solution

    SimpleViva wrap-up hai. Short thanks + confirm submission ZIP latest hai.

Advice: He is very calm, may ask some out of the box questions but its ok if you dont know them word by word, the understanding of the code is crucial, know your routes, know your models, just go thru every like of your code before giving viva.
  1. 1
    After that as I created a new student so he asked me to go on to the registration page back and asked me to add the same email, username which I just created for the previous question so I did that but could not be able to take that registration as I defined unique username and email so it gave a flash (user exists)so he said ok
    Times asked 1
    Official solution

    SimpleViva wrap-up hai. Short thanks + confirm submission ZIP latest hai.

  2. 2
    Then he asked me to go to the company dashboard again and asked to see in the application section of that drive to view if that students application is there or not.
    Times asked 1
    Official solution

    SimpleViva wrap-up hai. Short thanks + confirm submission ZIP latest hai.

  3. 3
    Then he asked that in that table in company_dashboard where I stored the ongoing drive details, add another column for the No. Of Application for each drives I started but forget how to count the application so he asked first of to use Google for syntax but I was trying so he told to use( | length) the. It worked.
    Times asked 1
    Official solution

    SimpleViva wrap-up hai. Short thanks + confirm submission ZIP latest hai.

  4. 4
    Then he asked to go to code and explain how I connected my flask app to database so I showed all the steps
    Times asked 1
    Official solution

    SimpleFlask lightweight Python web framework — routes, request/response, templates. MAD1 ka backend yahi hai.

    Example

    from flask import Flask
    app = Flask(__name__)
    
    @app.route('/')
    def home():
        return 'Hello'

    Viva tipFlask micro hai: jo chahiye (DB, login, forms) khud jodte ho.

  5. 5
    Then he asked to explain Authorization and Authentication in my code
    Times asked 1
    Official solution

    SimpleAuthentication: tu kaun hai? (login). Authorization: tujhe permission hai? (role check).

    Example

    # auth
    if check_password_hash(user.password, pwd):
        session['user_id'] = user.id
    
    # authz
    if user.role != 'admin':
        abort(403)
  6. 6
    Then he asked from the login route, what is the http method when we are displaying the flash message
    Times asked 1
    Official solution

    Simpleredirect dusre URL pe bhejta hai. flash one-time message session mein rakh ke next page pe dikhata hai.

    Example

    flash('Login successful', 'success')
    return redirect(url_for('user.dashboard'))
  7. 7
    Then he asked go to any other route for authorisation I used manually checking like for each route(if user_email is in session and whether the role is assigned to access the page details) for this he asked whether we can replace it with any simpler alternative I told for this we can use the flask-login and using decorator function @login-required then he said ok
    Times asked 1
    Official solution

    Simplelogin_required jaisa decorator protected routes pe: session nahi to login redirect.

    Example

    def login_required(fn):
        @wraps(fn)
        def wrapper(*a, **k):
            if 'user_id' not in session:
                return redirect(url_for('auth.login'))
            return fn(*a, **k)
        return wrapper
  8. 8
    Then he asked difference between POST, PUT, PATCH
    Times asked 1
    Official solution

    SimplePOST naya janam (har baar naya id). PUT poori photo replace. PATCH sticker chipkao.

    POST create, not idempotent. PUT full update, idempotent. PATCH partial.

    POST ki jagah PUT se REST semantics toot. GET typically no body.

    CRUD map: POST create, GET read, PUT/PATCH update, DELETE delete.

    Pehle 1-line definition, phir related MAD2 layer (Vue SFC / Flask route / models.py / tasks.py / Redis).

    4-line formula: input kahan se aaya, auth/validation kaunsa, DB ya cache ya Celery, kya return.

    Related mix mat karo — cache ≠ Celery, authentication ≠ authorization, v-if ≠ v-show, Beat ≠ Worker. Follow-up ke liye ek difference ready rakho.

    Example

    POST /api/venues
    PUT  /api/venues/1   {all fields}
    PATCH /api/venues/1 {only name}

    Project example: POST /api/venues create. PUT /venues/1 saari fields. PATCH sirf name.

  9. 9
    Then he asked whether I used bootstrap I said yes then he asked how so I showed the link which I used in base.html
    Times asked 1
    Official solution

    SimpleBootstrap CSS framework — grid, navbar, buttons jaldi. CDN ya downloaded files.

  10. 10
    He asked what is bootstrap why I used this
    Times asked 1
    Official solution

    SimpleBootstrap CSS framework — grid, navbar, buttons jaldi. CDN ya downloaded files.

  11. 11
    Then he asked as I have used the link so if there is weak internet or not internet connection so still this bootstrap will work or not, app will work or not. I said yes but then he said are you sure so I said I didn't tried it yet so he said ok
    Times asked 1
    Official solution

    SimpleBootstrap CSS framework — grid, navbar, buttons jaldi. CDN ya downloaded files.

  12. 12
    Then he asked go to company_dashboard on browser -> create drive option and he asked if I want to add another field for location or any other field so what will happen to other previously created drives
    Times asked 1
    Official solution

    SimpleDemo script pehle se practice: 5–7 min, Admin + User roles, saare mandatory features.

    Suggested flow1) Register/login user
    2) Admin login — CRUD
    3) Approval/blacklist
    4) Booking/apply + edge case
    5) Search
    6) Logout

    Viva tipBolte-bolte dikhao. Code tab kholna jab poochhein.

  13. 13
    Then he asked have you heard of catching I said no
    Times asked 1
    Official solution

    SimpleViva wrap-up hai. Short thanks + confirm submission ZIP latest hai.

Advice: He was kind and friendly. He was mainly interested in knowing whether the student has completed the project independently and know their own project whatever they have used and if used the AI or some tool so just know what you are using and what that line of code is doing.
  1. 1
    Download the file from VivaPortal.
    Times asked 2
    Official solution

    SimpleExaminer portal wala submitted ZIP chahta hai. Local extra changes mat dikhana.

    Suggested flow1) Portal ZIP download
    2) Extract
    3) venv + pip install -r requirements.txt
    4) flask run / python app.py

  2. 2
    Have you use any AI for your project ?
    Times asked 1
    Official solution

    SimplePehle 1-line definition, phir apne MAD1 project mein file dikhao, phir chhota example.

    Suggested flow1) Concept kya hai?
    2) Mere code mein kahan?
    3) Example / demo
    4) Edge case

    Example

    # related file: models.py / routes / template
    # formula: request → check/auth → DB → render/redirect

    Viva tipExact line yaad nahi to honestly related part dikhao. Bluff mat karo.

  3. 3
    Asked the 2 questions based on coding like you explain what does line no ___(any number) do.
    Times asked 1
    Official solution

    SimpleCode explain formula: input kya aaya → auth/validation → DB change → response/UI.

    Viva tipFunction signature + 3-4 important lines + edge case.

  4. 4
    Asked to add the confirmed password code in student registration page.
    Times asked 1
    Official solution

    SimpleLive Flask coding: chhota route likho, save, browser/curl se test. Syntax error terminal mein padho.

    Example

    @app.route('/ping')
    def ping():
        return jsonify(ok=True)
    
    @app.route('/even/<int:n>')
    def even(n):
        return 'even' if n % 2 == 0 else 'odd'
  5. 5
    What is POST, PUT and PATCH ?
    Times asked 1
    Official solution

    SimplePOST naya janam (har baar naya id). PUT poori photo replace. PATCH sticker chipkao.

    POST create, not idempotent. PUT full update, idempotent. PATCH partial.

    POST ki jagah PUT se REST semantics toot. GET typically no body.

    CRUD map: POST create, GET read, PUT/PATCH update, DELETE delete.

    Pehle 1-line definition, phir related MAD2 layer (Vue SFC / Flask route / models.py / tasks.py / Redis).

    4-line formula: input kahan se aaya, auth/validation kaunsa, DB ya cache ya Celery, kya return.

    Related mix mat karo — cache ≠ Celery, authentication ≠ authorization, v-if ≠ v-show, Beat ≠ Worker. Follow-up ke liye ek difference ready rakho.

    Example

    POST /api/venues
    PUT  /api/venues/1   {all fields}
    PATCH /api/venues/1 {only name}

    Project example: POST /api/venues create. PUT /venues/1 saari fields. PATCH sirf name.

Advice: Proctor was good and helped me to understand the question he asked by commenting in the GMeet chatbox. And I can able to answer well. Some questions I don't answer properly but sir understood. Level2 Viva went well. So, be thorough with your app.py coding in your project and answer well. Just look for common questions in previous term viva questions and go through your project coding which will be asked in Level2 viva. Be patient and don't get nervous in Level2 as it is important.
  1. 1
    He said good morning and asked me how i was doing then i told him i was nervous but he was like don't be
    Times asked 1
    Official solution

    SimpleViva wrap-up hai. Short thanks + confirm submission ZIP latest hai.

  2. 2
    1.demonstrate the app
    Times asked 1
    Official solution

    SimpleDemo script pehle se practice: 5–7 min, Admin + User roles, saare mandatory features.

    Suggested flow1) Register/login user
    2) Admin login — CRUD
    3) Approval/blacklist
    4) Booking/apply + edge case
    5) Search
    6) Logout

    Viva tipBolte-bolte dikhao. Code tab kholna jab poochhein.

  3. 3
    3.he is interested in knowing what i wrote in the code and asked me why i wrote this that etc
    Times asked 1
    Official solution

    SimpleLive Flask coding: chhota route likho, save, browser/curl se test. Syntax error terminal mein padho.

    Example

    @app.route('/ping')
    def ping():
        return jsonify(ok=True)
    
    @app.route('/even/<int:n>')
    def even(n):
        return 'even' if n % 2 == 0 else 'odd'
Advice: Know your code very well like be ready to explain your kinda theoretically too. Sir is very calm and chill and polite. He is a young guy so i felt like he was more understanding. Even if u don't know the exact answer, say something related to it atleast. He is a very patient man is what i personally felt. I couldnt run my app because of net issues for like 15min but he was calm and that made me feel at ease.
  1. 1
    checksum and oppe setup
    Times asked 1
    Official solution

    SimpleExaminer wohi ZIP chahta hai jo tumne submit kiya, local extra magic nahi.

    Portal download → extract → redis, venv, pip, npm, flask, worker, beat.

    Checksum maange to hash. Uncommitted files mat dikhana.

    Examiner 2 cheezein: simple desi line + tumhare project ki exact file.

    Pehle ID, GitHub, portal ZIP. Phir run: Redis + Flask + worker + beat + Vue. Feature demo: login, RBAC, cache hit/miss, Celery mail, search.

    Line pe ungli: input kahan, kaunsa check, query/cache/task, JSON/UI. Copilot band. Jo nahi kiya honestly bolo + kaise add karte.

    Suggested flow1) ZIP
    2) Extract
    3) Redis + venv + pip
    4) npm/vite
    5) flask + celery worker + beat

    Project example: Submitted zip run. README commands copy.

    Viva tipChecksum maange to hash match karke dikhao. Extra uncommitted files mat dikhana.

  2. 2
    demo (checking functionality)
    Times asked 1
    Official solution

    SimpleDemo script pehle se practice: 5–7 min, Admin + User roles, saare mandatory features.

    Suggested flow1) Register/login user
    2) Admin login — CRUD
    3) Approval/blacklist
    4) Booking/apply + edge case
    5) Search
    6) Logout

    Viva tipBolte-bolte dikhao. Code tab kholna jab poochhein.

  3. 3
    where is authentication and authorization implemented
    Times asked 1
    Official solution

    SimpleAuthentication: tu kaun hai? (login). Authorization: tujhe permission hai? (role check).

    Example

    # auth
    if check_password_hash(user.password, pwd):
        session['user_id'] = user.id
    
    # authz
    if user.role != 'admin':
        abort(403)
  4. 4
    how relations are defined between models (in code)
    Times asked 1
    Official solution

    Simplemodels.py = har table ki class: columns, PK/FK, relationships. Yeh Model layer hai.

    Suggested flow1) Classes list karo
    2) Har table ka kaam 1 line
    3) Relationships (1-M / M-M)
    4) Constraints (unique, nullable)

    Example

    class Lot(db.Model):
        id = db.Column(db.Integer, primary_key=True)
        name = db.Column(db.String(80), nullable=False)
        spots = db.relationship('Spot', backref='lot', lazy=True)
  5. 5
    (code): make sure no doctor with existing bookings gets deleted
    Times asked 1
    Official solution

    SimpleLive UI change: relevant CSS/HTML template kholo — color, margin, flex, bootstrap class. Save + hard refresh.

    Example

    /* button red */
    .btn-primary { background: red; }
    
    /* center navbar item */
    .navbar { justify-content: center; }

    Viva tipDevTools se pehle try, phir file mein permanent change.

  6. 6
    exception handling and HTTP codes
    Times asked 1
    Official solution

    Simpletry/except. Catch Exception not BaseException (SystemExit). IntegrityError 404 abort.

    Exception handling. Types ValueError TypeError KeyError IntegrityError HTTPException.

    Pehle 1-line definition, phir related MAD2 layer (Vue SFC / Flask route / models.py / tasks.py / Redis).

    4-line formula: input kahan se aaya, auth/validation kaunsa, DB ya cache ya Celery, kya return.

    Related mix mat karo — cache ≠ Celery, authentication ≠ authorization, v-if ≠ v-show, Beat ≠ Worker. Follow-up ke liye ek difference ready rakho.

    Example

    try:
        db.session.commit()
    except IntegrityError:
        db.session.rollback()
        return jsonify(msg='duplicate'), 400

    Project example: commit except rollback 400.

  7. 7
    where is bootstrapping in the code and where and how is it used
    Times asked 1
    Official solution

    SimpleBootstrap CSS framework — grid, navbar, buttons jaldi. CDN ya downloaded files.

  8. 8
    if i am familiar with javascript, i told him i wasn't but the charts in my project were js which i created using AI and he said using llms for extra functionalities is fine :)
    Times asked 1
    Official solution

    SimpleProject overview: problem → roles → main entities → key flows (register, book, admin approve).

    Viva tip1 minute elevator pitch ready rakho, phir demo.

  9. 9
    are you interested in app dev the viva lasted for less than 30 minutes, he said i did well and had a good understanding of the flow of code in my project and my basics were clear, all in all pretty straightforward questions, might point to certain lines in the code or ask questions like "where is the current user getting initialized in the code"
    Times asked 1
    Official solution

    SimpleProject overview: problem → roles → main entities → key flows (register, book, admin approve).

    Viva tip1 minute elevator pitch ready rakho, phir demo.

Advice: look into the questions he's asked previously, he's pretty chill if you don't know certain things as long as your basics are clear you're good, you got this!
  1. 1
    1.demo
    Times asked 2
    Official solution

    SimpleDemo script pehle se practice: 5–7 min, Admin + User roles, saare mandatory features.

    Suggested flow1) Register/login user
    2) Admin login — CRUD
    3) Approval/blacklist
    4) Booking/apply + edge case
    5) Search
    6) Logout

    Viva tipBolte-bolte dikhao. Code tab kholna jab poochhein.

  2. 2
    2.mainly he focused on doctor's
    Times asked 1
    Official solution

    SimplePehle 1-line definition, phir apne MAD1 project mein file dikhao, phir chhota example.

    Suggested flow1) Concept kya hai?
    2) Mere code mein kahan?
    3) Example / demo
    4) Edge case

    Example

    # related file: models.py / routes / template
    # formula: request → check/auth → DB → render/redirect

    Viva tipExact line yaad nahi to honestly related part dikhao. Bluff mat karo.

  3. 3
    4.about Authorization and authentication and its implementation
    Times asked 1
    Official solution

    SimpleAuthentication: tu kaun hai? (login). Authorization: tujhe permission hai? (role check).

    Example

    # auth
    if check_password_hash(user.password, pwd):
        session['user_id'] = user.id
    
    # authz
    if user.role != 'admin':
        abort(403)
  4. 4
    6.write a code so that admin cannot delete a doctor if he has active appointment using appointment id and doctor if(I have appointment table)
    Times asked 1
    Official solution

    SimpleLive Flask coding: chhota route likho, save, browser/curl se test. Syntax error terminal mein padho.

    Example

    @app.route('/ping')
    def ping():
        return jsonify(ok=True)
    
    @app.route('/even/<int:n>')
    def even(n):
        return 'even' if n % 2 == 0 else 'odd'
  5. 5
    7 .about reln between appointment and doctors,patient
    Times asked 1
    Official solution

    SimplePehle 1-line definition, phir apne MAD1 project mein file dikhao, phir chhota example.

    Suggested flow1) Concept kya hai?
    2) Mere code mein kahan?
    3) Example / demo
    4) Edge case

    Example

    # related file: models.py / routes / template
    # formula: request → check/auth → DB → render/redirect

    Viva tipExact line yaad nahi to honestly related part dikhao. Bluff mat karo.

Advice: Go through the previous questions in the form he is chill and nice guy accept it if u don't know the ans but get good understanding about ur code
  1. 1
    Level 2 viva :
    Times asked 1
    Official solution

    SimpleLevel = viva difficulty band. Level 1 usually demo + basics; higher pe live coding + deeper theory.

    Viva tipJo level assign hai uske hisaab se demo + theory ready rakho.

  2. 2
    - Asked me to set up my camera, download project, checked id card as well and asked me to run my app
    Times asked 1
    Official solution

    SimpleCamera pe clearly college/IITM ID dikhao — naam aur photo match hone chahiye.

    Viva tipPehle se ID haath mein rakho, glare mat aane do. Iske baad GitHub + project run.

  3. 3
    - started with the demo but he himself started mentioning what he wants to see further so went with that, He majorly checked creating doctors and booking appointments giving availablity etc.
    Times asked 1
    Official solution

    SimpleDemo script pehle se practice: 5–7 min, Admin + User roles, saare mandatory features.

    Suggested flow1) Register/login user
    2) Admin login — CRUD
    3) Approval/blacklist
    4) Booking/apply + edge case
    5) Search
    6) Logout

    Viva tipBolte-bolte dikhao. Code tab kholna jab poochhein.

  4. 4
    - asked a bit about models like why have I used orm, why user mixin, just basic questions over random code he could see
    Times asked 1
    Official solution

    SimpleORM = Object Relational Mapping. Tables → Python classes. Raw SQL kam likhte ho.

    Example

    class User(db.Model):
        id = db.Column(db.Integer, primary_key=True)
        email = db.Column(db.String(120), unique=True)
    
    User.query.get(5)  # SELECT ... WHERE id=5
  5. 5
    - same for routes, he specifically asked for doctor delete route and asked me to make a change so that if a doctor has upcoming appointment, admin gets a warning message
    Times asked 1
    Official solution

    SimpleLive UI change: relevant CSS/HTML template kholo — color, margin, flex, bootstrap class. Save + hard refresh.

    Example

    /* button red */
    .btn-primary { background: red; }
    
    /* center navbar item */
    .navbar { justify-content: center; }

    Viva tipDevTools se pehle try, phir file mein permanent change.

  6. 6
    - in models, asked for relationship between appointments, doctor and patient
    Times asked 1
    Official solution

    Simpledb.relationship se object graph: lot.spots, booking.user. backref reverse side auto deta hai.

    Example

    spots = db.relationship('Spot', backref='lot', cascade='all, delete-orphan')
  7. 7
    - also asked why did I have extensions.py (i was getting a circular import problem in my models.py and app.py that's why I had that so I explained the same)
    Times asked 1
    Official solution

    Simplemodels.py = har table ki class: columns, PK/FK, relationships. Yeh Model layer hai.

    Suggested flow1) Classes list karo
    2) Har table ka kaam 1 line
    3) Relationships (1-M / M-M)
    4) Constraints (unique, nullable)

    Example

    class Lot(db.Model):
        id = db.Column(db.Integer, primary_key=True)
        name = db.Column(db.String(80), nullable=False)
        spots = db.relationship('Spot', backref='lot', lazy=True)
Advice: The proctor is really calm and nice, he just focuses on the project and ask relevant questions, doesn't go for theory much. The proctor really just wants to check if the student is clear with the basics of app, for the rest he does help with writing code, i was nervous while editing the code so he did explain me what I should be doing and why is it necessary so it was really nice of him, so yes just be thorough with your basics and code that's enough to convince him, my viva ended in like 30 mins where the first 10 mins was all about setting up mobile, downloading app etc.
  1. 1
    demo(has asked do this try this and this means he check s the functionality in the demo only he wants)
    Times asked 1
    Official solution

    SimpleDemo script pehle se practice: 5–7 min, Admin + User roles, saare mandatory features.

    Suggested flow1) Register/login user
    2) Admin login — CRUD
    3) Approval/blacklist
    4) Booking/apply + edge case
    5) Search
    6) Logout

    Viva tipBolte-bolte dikhao. Code tab kholna jab poochhein.

  2. 2
    then asked about the route he pointed out the line number to explain its usage
    Times asked 1
    Official solution

    SimpleCode explain formula: input kya aaya → auth/validation → DB change → response/UI.

    Viva tipFunction signature + 3-4 important lines + edge case.

  3. 3
    how database is created how it is connected to your app
    Times asked 1
    Official solution

    SimpleCode explain formula: input kya aaya → auth/validation → DB change → response/UI.

    Viva tipFunction signature + 3-4 important lines + edge case.

  4. 4
    asked about relationships
    Times asked 1
    Official solution

    Simpledb.relationship se object graph: lot.spots, booking.user. backref reverse side auto deta hai.

    Example

    spots = db.relationship('Spot', backref='lot', cascade='all, delete-orphan')
  5. 5
    how you implemented authorization in code
    Times asked 1
    Official solution

    SimpleAuthentication: tu kaun hai? (login). Authorization: tujhe permission hai? (role check).

    Example

    # auth
    if check_password_hash(user.password, pwd):
        session['user_id'] = user.id
    
    # authz
    if user.role != 'admin':
        abort(403)
  6. 6
    Bootstrap how used and why
    Times asked 1
    Official solution

    SimpleBootstrap CSS framework — grid, navbar, buttons jaldi. CDN ya downloaded files.

  7. 7
    scaling(not directly but with scenario what if multiple user try to your app)
    Times asked 1
    Official solution

    SimpleLoad badhe to handle: scale up/out, cache, async, DB tune.

    SQL scale: indexes, pool, replicas, partition, cache hot queries.

    Pehle 1-line definition, phir related MAD2 layer (Vue SFC / Flask route / models.py / tasks.py / Redis).

    4-line formula: input kahan se aaya, auth/validation kaunsa, DB ya cache ya Celery, kya return.

    Related mix mat karo — cache ≠ Celery, authentication ≠ authorization, v-if ≠ v-show, Beat ≠ Worker. Follow-up ke liye ek difference ready rakho.

    Project example: If 10k: URI postgres, gunicorn, cache, celery concurrency.

  8. 8
    code written
    Times asked 1
    Official solution

    SimpleViva wrap-up hai. Short thanks + confirm submission ZIP latest hai.

  9. 9
    on doctors registration page add confirm password then validate in route
    Times asked 1
    Official solution

    SimpleValidation = input rules: required, email format, length, unique. Frontend UX, backend security — dono.

    Example

    if not email or '@' not in email:
        flash('Invalid email')
        return redirect(request.url)
    if User.query.filter_by(email=email).first():
        flash('Email taken')
  10. 10
    give scenario what and how you handle the situation if we want to add city to the doctor field how you would approach
    Times asked 1
    Official solution

    SimplePehle 1-line definition, phir apne MAD1 project mein file dikhao, phir chhota example.

    Suggested flow1) Concept kya hai?
    2) Mere code mein kahan?
    3) Example / demo
    4) Edge case

    Example

    # related file: models.py / routes / template
    # formula: request → check/auth → DB → render/redirect

    Viva tipExact line yaad nahi to honestly related part dikhao. Bluff mat karo.

Advice: keep calm he also helped you in code if you stuck just go through the question get ready to face practical questions instead of direct theory questions
  1. 1
    Viva 2 Asked me to show the ID card first and then asked me to download the code from the website and run it Then showed the demo, the proctor asked for some functionalities mainly CRUD and some edge test cases. Was asking a lot of questions as I was giving the demo like(Also I was explaining some of the things while I explaining the demo alongside code)
    Times asked 1
    Official solution

    SimpleCamera pe clearly college/IITM ID dikhao — naam aur photo match hone chahiye.

    Viva tipPehle se ID haath mein rakho, glare mat aane do. Iske baad GitHub + project run.

  2. 2
    model part of your code - relationship between tables, cascading
    Times asked 1
    Official solution

    Simpledb.relationship se object graph: lot.spots, booking.user. backref reverse side auto deta hai.

    Example

    spots = db.relationship('Spot', backref='lot', cascade='all, delete-orphan')
  3. 3
    Frameworks used
    Times asked 3
    Official solution

    SimpleStack bolo: Python, Flask, Jinja2, SQLAlchemy, SQLite, HTML/CSS/Bootstrap, maybe Chart.js.

  4. 4
    CSS and bootstrapping
    Times asked 1
    Official solution

    SimpleBootstrap CSS framework — grid, navbar, buttons jaldi. CDN ya downloaded files.

  5. 5
    creating a route for a new page which displays the occupied spots in a particular lot
    Times asked 1
    Official solution

    SimplePehle 1-line definition, phir apne MAD1 project mein file dikhao, phir chhota example.

    Suggested flow1) Concept kya hai?
    2) Mere code mein kahan?
    3) Example / demo
    4) Edge case

    Example

    # related file: models.py / routes / template
    # formula: request → check/auth → DB → render/redirect

    Viva tipExact line yaad nahi to honestly related part dikhao. Bluff mat karo.

  6. 6
    JavaScript ( I have used some) - asked about DOM
    Times asked 1
    Official solution

    SimplePehle 1-line definition, phir apne MAD1 project mein file dikhao, phir chhota example.

    Suggested flow1) Concept kya hai?
    2) Mere code mein kahan?
    3) Example / demo
    4) Edge case

    Example

    # related file: models.py / routes / template
    # formula: request → check/auth → DB → render/redirect

    Viva tipExact line yaad nahi to honestly related part dikhao. Bluff mat karo.

  7. 7
    how do you scale your application ( scale up Vs scale down)
    Times asked 1
    Official solution

    SimpleCode explain formula: input kya aaya → auth/validation → DB change → response/UI.

    Viva tipFunction signature + 3-4 important lines + edge case.

Advice: Be practical with your code, cover edge cases and if you hadn't done them, mention them beforehand itself
  1. 1
    L3_42
    Times asked 1
    Official solution

    SimpleViva wrap-up hai. Short thanks + confirm submission ZIP latest hai.

  2. 2
    How db getting created
    Times asked 1
    Official solution

    SimpleCode explain formula: input kya aaya → auth/validation → DB change → response/UI.

    Viva tipFunction signature + 3-4 important lines + edge case.

  3. 3
    Jinja why it's used
    Times asked 1
    Official solution

    SimpleJinja2 Flask ka template engine — HTML ke andar {{ }} variables, {% %} logic.

    Example

    {% for lot in lots %}
      <li>{{ lot.name }} — {{ lot.spots }}</li>
    {% else %}
      <p>No lots</p>
    {% endfor %}
  4. 4
    Bootstrap,how we import it ,uses
    Times asked 1
    Official solution

    SimpleBootstrap CSS framework — grid, navbar, buttons jaldi. CDN ya downloaded files.

  5. 5
    Explain relationship in your db
    Times asked 1
    Official solution

    Simpledb.relationship se object graph: lot.spots, booking.user. backref reverse side auto deta hai.

    Example

    spots = db.relationship('Spot', backref='lot', cascade='all, delete-orphan')
  6. 6
    Code change:
    Times asked 2
    Official solution

    SimpleViva wrap-up hai. Short thanks + confirm submission ZIP latest hai.

  7. 7
    Asked me to add confirm password field
    Times asked 1
    Official solution

    SimplePehle 1-line definition, phir apne MAD1 project mein file dikhao, phir chhota example.

    Suggested flow1) Concept kya hai?
    2) Mere code mein kahan?
    3) Example / demo
    4) Edge case

    Example

    # related file: models.py / routes / template
    # formula: request → check/auth → DB → render/redirect

    Viva tipExact line yaad nahi to honestly related part dikhao. Bluff mat karo.

  8. 8
    Make changes in edit parking lot route
    Times asked 1
    Official solution

    SimpleProject overview: problem → roles → main entities → key flows (register, book, admin approve).

    Viva tip1 minute elevator pitch ready rakho, phir demo.

  9. 9
    Also asked me if this my field of interest (I said no doing it for project only)
    Times asked 1
    Official solution

    SimplePehle 1-line definition, phir apne MAD1 project mein file dikhao, phir chhota example.

    Suggested flow1) Concept kya hai?
    2) Mere code mein kahan?
    3) Example / demo
    4) Edge case

    Example

    # related file: models.py / routes / template
    # formula: request → check/auth → DB → render/redirect

    Viva tipExact line yaad nahi to honestly related part dikhao. Bluff mat karo.

  10. 10
    Lasted for roughly 50 mins
    Times asked 1
    Official solution

    SimpleViva wrap-up hai. Short thanks + confirm submission ZIP latest hai.

Advice: He's nice ,patient ,gave time to think and (he doesn't focus on theory much basic simple question) He asked practical questions mostly Use headphones
  1. 1
    He asked me a lot of coding questions.
    Times asked 1
    Official solution

    SimpleLive coding: notepad/editor mein chhota Flask route / Jinja loop / model field. Calm raho, run karke dikhao.

  2. 2
    He made me write code, including routes.
    Times asked 1
    Official solution

    SimpleLive Flask coding: chhota route likho, save, browser/curl se test. Syntax error terminal mein padho.

    Example

    @app.route('/ping')
    def ping():
        return jsonify(ok=True)
    
    @app.route('/even/<int:n>')
    def even(n):
        return 'even' if n % 2 == 0 else 'odd'
  3. 3
    Asked about ORM (Object-Relational Mapping).
    Times asked 1
    Official solution

    SimpleORM = Object Relational Mapping. Tables → Python classes. Raw SQL kam likhte ho.

    Example

    class User(db.Model):
        id = db.Column(db.Integer, primary_key=True)
        email = db.Column(db.String(120), unique=True)
    
    User.query.get(5)  # SELECT ... WHERE id=5
  4. 4
    Asked me to write code to enforce an alphanumeric password and throw an error for basic passwords like "1234".
    Times asked 1
    Official solution

    SimpleInt column mein string daalne pe SQLAlchemy/DB type error ya Integrity/StatementError. Empty table pe bhi same validation fail — row count matter nahi.

    Example

    # SQLite may coerce sometimes; Postgres: invalid input syntax for integer
    Spot(status='free', lot_id='abc')  # lot_id int → error
  5. 5
    Asked about sessions and their purpose.
    Times asked 1
    Official solution

    SimpleMAD1 mein usually session-based auth: login pe session['user_id'], har request pe verify.

    Example

    session['user_id'] = user.id
    uid = session.get('user_id')
    user = User.query.get(uid)

    Viva tipSECRET_KEY set karo warna session insecure. logout pe session.clear().

  6. 6
    Focused more on practical implementation rather than theory.
    Times asked 1
    Official solution

    SimpleTheory = concepts: ORM, MVC, auth vs authz, Jinja inheritance, sessions. 1-line def + project example.

Advice: Just stay calm and honest… He’s going to ask you a lot of technical questions about how you did this. The viva lasted about 45 minutes, so make sure to review your routing.py.
  1. 1
    Level 1:
    Times asked 3
    Official solution

    SimpleLevel = viva difficulty band. Level 1 usually demo + basics; higher pe live coding + deeper theory.

    Viva tipJo level assign hai uske hisaab se demo + theory ready rakho.

  2. 2
    How you implemented month's wise number of quizzes attempted
    Times asked 1
    Official solution

    SimpleCode explain formula: input kya aaya → auth/validation → DB change → response/UI.

    Viva tipFunction signature + 3-4 important lines + edge case.

  3. 3
    How you are deleting all chapters and it's related quizzes in your database
    Times asked 1
    Official solution

    SimpleCode explain formula: input kya aaya → auth/validation → DB change → response/UI.

    Viva tipFunction signature + 3-4 important lines + edge case.

  4. 4
    Difference between Restful get and Patch ( basically difference) Level 2:
    Times asked 1
    Official solution

    SimpleREST: resources + HTTP verbs. GET read, POST create, PUT/PATCH update, DELETE remove. Stateless ideal.

  5. 5
    How app.py work (like the application workflow)
    Times asked 1
    Official solution

    SimpleCode explain formula: input kya aaya → auth/validation → DB change → response/UI.

    Viva tipFunction signature + 3-4 important lines + edge case.

  6. 6
    Questions on database (like how cascading work)
    Times asked 1
    Official solution

    SimplePehle 1-line definition, phir apne MAD1 project mein file dikhao, phir chhota example.

    Suggested flow1) Concept kya hai?
    2) Mere code mein kahan?
    3) Example / demo
    4) Edge case

    Example

    # related file: models.py / routes / template
    # formula: request → check/auth → DB → render/redirect

    Viva tipExact line yaad nahi to honestly related part dikhao. Bluff mat karo.

  7. 7
    questions about ports (like 302, 402 etc..)
    Times asked 1
    Official solution

    SimplePehle 1-line definition, phir apne MAD1 project mein file dikhao, phir chhota example.

    Suggested flow1) Concept kya hai?
    2) Mere code mein kahan?
    3) Example / demo
    4) Edge case

    Example

    # related file: models.py / routes / template
    # formula: request → check/auth → DB → render/redirect

    Viva tipExact line yaad nahi to honestly related part dikhao. Bluff mat karo.

  8. 8
    Difference between Get, Push.
    Times asked 1
    Official solution

    SimpleUngli rakhe to 4-line formula — panic ki jagah structure.

    1) File ka role: model / Flask route / Vue SFC / celery task / config
    2) Input kahan: JSON, params, token, props, $route
    3) Kya kaam: query, cache, validation, .delay()
    4) Output: jsonify, this.items, email, redirect

    Unknown keyword: import, decorator, if, commit — har ka reason. Bluff mat.

    Suggested flow1) Kaunsi layer?
    2) Input?
    3) DB/cache/task?
    4) Response/UI?

    Project example: Booking POST: jwt, seats check, commit, 201, Vue list push.

    Viva tipUnknown keyword: import, decorator, if, commit — har ka reason. Panic mat.

  9. 9
    How you will scale your website basically scalability question.
    Times asked 1
    Official solution

    SimpleCode explain formula: input kya aaya → auth/validation → DB change → response/UI.

    Viva tipFunction signature + 3-4 important lines + edge case.

  10. 10
    Modify date of the quiz to only take present or future date.
    Times asked 1
    Official solution

    SimplePehle 1-line definition, phir apne MAD1 project mein file dikhao, phir chhota example.

    Suggested flow1) Concept kya hai?
    2) Mere code mein kahan?
    3) Example / demo
    4) Edge case

    Example

    # related file: models.py / routes / template
    # formula: request → check/auth → DB → render/redirect

    Viva tipExact line yaad nahi to honestly related part dikhao. Bluff mat karo.

  11. 11
    Why you didn't use an API
    Times asked 1
    Official solution

    SimplePehle 1-line definition, phir apne MAD1 project mein file dikhao, phir chhota example.

    Suggested flow1) Concept kya hai?
    2) Mere code mein kahan?
    3) Example / demo
    4) Edge case

    Example

    # related file: models.py / routes / template
    # formula: request → check/auth → DB → render/redirect

    Viva tipExact line yaad nahi to honestly related part dikhao. Bluff mat karo.

Advice: Tip for level 1: 1. Don't be scared, be confident. 2. If you don't know any answer then answer something which is related to that question. 3. If you don't know anything about the question then just say, sorry sir/mam I can't recall it now. 4. Level 1 viva is simple you just need to give your demo properly. 5. Focus on database more in level 1 viva. 6. Ask for feedback before leaving the meet.
  1. 1
    Cloud Services
    Times asked 1
    Official solution

    SimpleViva wrap-up hai. Short thanks + confirm submission ZIP latest hai.

  2. 2
    What should you change in order to manage thousands of requests in a single machine
    Times asked 1
    Official solution

    SimpleLive UI change: relevant CSS/HTML template kholo — color, margin, flex, bootstrap class. Save + hard refresh.

    Example

    /* button red */
    .btn-primary { background: red; }
    
    /* center navbar item */
    .navbar { justify-content: center; }

    Viva tipDevTools se pehle try, phir file mein permanent change.

Advice: Know your project very well, he'll tell you to change functionality, so first explain how you are going to proceed and then go ahead
  1. 1
    Show your College ID.
    Times asked 16
    Official solution

    SimpleCamera pe clearly IITM/college ID dikhao — naam photo match.

    Pehle se ID haath mein rakho. Glare mat aane do. Examiner screenshot/verify karta hai. Iske baad GitHub + project run.

  2. 2
    Download the project from the Viva Portal.
    Times asked 7
    Official solution

    SimpleExaminer submitted ZIP chahta hai, local extra changes nahi.

    Portal se ZIP download → extract → venv → pip install -r requirements.txt → flask run / python app.py.
    Checksum maange to hash match karke dikhao. Camera/OPPE setup unke instructions.
    Linux/Mac: paths, gunicorn; Windows paths alag ho to relative paths use karo.
    Do browsers: admin + user parallel demo impressive lagta hai.

  3. 3
    Run checksum.
    Times asked 3
    Official solution

    SimpleChecksum file ka hash (jaise SHA256) — file change hui ya nahi verify.

    Portal pe submitted ZIP ka checksum diya hota hai. Local file ka hash nikaalo, match hona chahiye.
    Linux: sha256sum project.zip
    Mismatch = galat file / corrupt download. Examiner integrity check karta hai ki tumhari submitted copy hi run ho rahi hai.

  4. 4
    Demonstrate the application.
    Times asked 4
    Official solution

    SimpleDemo script pehle se practice karo, 5-7 minute, saari roles.

    Suggested flow

    1) Register/login user 2) Admin login — CRUD 3) Approval/blacklist 4) Booking/apply 5) Search 6) Validation edge (slots 0, duplicate) 7) Logout
    Bolte-bolte dikhao: 'Yahan overbooking rokta hoon'. Code tab kholna jab poochhein.
    Crash ho to debug calmly: terminal error, typo, DB path.
    Mandatory features skip mat karna — examiner list tick karta hai.

  5. 5
    Perform specific workflows during the demo (e.g., create doctor/company drive/trek, booking, applications, etc.).
    Times asked 1
    Official solution

    Yeh feature demo hai. Account ready rakho, steps bol ke dikhao.

    Role ke hisaab login → action (create/approve/book) → DB/UI pe result → edge case (fail when slots=0 / blacklisted).
    Do browser windows: admin + user. Search/filter alag se dikhao.
    Agar feature nahi hai to sach bolo aur 2 minute mein kaise add karoge (query + template) explain karo.

  6. 6
    Explain the complete application flow (app.py workflow).
    Times asked 1
    Official solution

    SimpleRoutes/controllers URLs handle karte hain. app.py app banata hai, models.py data, templates/ views, static/ CSS-JS.

    Typical structure:
    app.py / __init__.py → Flask app, db.init, register blueprints
    models.py → tables
    routes.py / views → @app.route functions
    templates/ → Jinja HTML
    static/ → css, images
    instance/*.db → SQLite

    Ek route explain karne ka template:
    1) URL + methods 2) Auth/role check 3) Form/query se data 4) Business rule (duplicate, slots) 5) db.session 6) render ya redirect

    Example GET+POST same route: GET form, POST save.
    Data HTML se: form name= → request.form. Data HTML ko: render_template(..., items=query).
    Nayi .py file: import karke use karo, warna Flask ko pata nahi. Folder rename: imports/paths/templates check.

  7. 7
    Explain how the Flask application is connected to the database.
    Times asked 1
    Official solution

    Examiner code pe ungli rakh ke poochta hai — panic mat karo, 4-line formula bolo.

    1) Yeh file/line kya role hai (model / route / template / config)?
    2) Input kahan se aata hai (form, URL <id>, session, JSON)?
    3) DB pe kya query/write?
    4) Output kya (render_template / redirect / jsonify)?

    Example

    @app.route('/book/<int:id>', methods=['POST']) — logged-in user session se, trek id URL se, Booking add, slots--, redirect history.

    Unknown line: imports (request, url_for, flash), decorators, if checks, commit — har keyword ka reason ready rakho.

  8. 8
    Explain a specific route or line of code.
    Times asked 1
    Official solution

    SimpleRoutes/controllers URLs handle karte hain. app.py app banata hai, models.py data, templates/ views, static/ CSS-JS.

    Typical structure:
    app.py / __init__.py → Flask app, db.init, register blueprints
    models.py → tables
    routes.py / views → @app.route functions
    templates/ → Jinja HTML
    static/ → css, images
    instance/*.db → SQLite

    Ek route explain karne ka template:
    1) URL + methods 2) Auth/role check 3) Form/query se data 4) Business rule (duplicate, slots) 5) db.session 6) render ya redirect

    Example GET+POST same route: GET form, POST save.
    Data HTML se: form name= → request.form. Data HTML ko: render_template(..., items=query).
    Nayi .py file: import karke use karo, warna Flask ko pata nahi. Folder rename: imports/paths/templates check.

  9. 9
    Explain the workflow of a route.
    Times asked 1
    Official solution

    SimpleRoutes/controllers URLs handle karte hain. app.py app banata hai, models.py data, templates/ views, static/ CSS-JS.

    Typical structure:
    app.py / __init__.py → Flask app, db.init, register blueprints
    models.py → tables
    routes.py / views → @app.route functions
    templates/ → Jinja HTML
    static/ → css, images
    instance/*.db → SQLite

    Ek route explain karne ka template:
    1) URL + methods 2) Auth/role check 3) Form/query se data 4) Business rule (duplicate, slots) 5) db.session 6) render ya redirect

    Example GET+POST same route: GET form, POST save.
    Data HTML se: form name= → request.form. Data HTML ko: render_template(..., items=query).
    Nayi .py file: import karke use karo, warna Flask ko pata nahi. Folder rename: imports/paths/templates check.

  10. 10
    Explain how the database is created and connected to the application.
    Times asked 1
    Official solution

    Examiner code pe ungli rakh ke poochta hai — panic mat karo, 4-line formula bolo.

    1) Yeh file/line kya role hai (model / route / template / config)?
    2) Input kahan se aata hai (form, URL <id>, session, JSON)?
    3) DB pe kya query/write?
    4) Output kya (render_template / redirect / jsonify)?

    Example

    @app.route('/book/<int:id>', methods=['POST']) — logged-in user session se, trek id URL se, Booking add, slots--, redirect history.

    Unknown line: imports (request, url_for, flash), decorators, if checks, commit — har keyword ka reason ready rakho.

  11. 11
    Explain how relationships are defined in your models.
    Times asked 1
    Official solution

    Simplemodels.py har table ki class hai — columns, PK/FK, relationships. Yeh Model layer hai.

    Viva mein file khol ke bolo:
    1) Kaunsi classes/tables hain (User, Role-specific, Booking...)
    2) Har table ka kaam 1 line
    3) Relationships: 1-1 / 1-M / M-M, backref, cascade, lazy
    4) Constraints: unique email, nullable, default status

    Example skeleton

    class User(db.Model):
        id = db.Column(db.Integer, primary_key=True)
        email = db.Column(db.String(120), unique=True, nullable=False)
        role = db.Column(db.String(20), default='user')
        bookings = db.relationship('Booking', backref='user', cascade='all, delete-orphan')

    ER diagram: rectangles entities, lines relationships, PK/FK mark. Schema = yahi structure.
    Tables create: db.create_all() ya migrations. SQLite file SQL viewer se dikha sakte ho.

  12. 12
    Explain the relationship between related models (e.g., Doctor–Patient–Appointment).
    Times asked 1
    Official solution

    Simplemodels.py har table ki class hai — columns, PK/FK, relationships. Yeh Model layer hai.

    Viva mein file khol ke bolo:
    1) Kaunsi classes/tables hain (User, Role-specific, Booking...)
    2) Har table ka kaam 1 line
    3) Relationships: 1-1 / 1-M / M-M, backref, cascade, lazy
    4) Constraints: unique email, nullable, default status

    Example skeleton

    class User(db.Model):
        id = db.Column(db.Integer, primary_key=True)
        email = db.Column(db.String(120), unique=True, nullable=False)
        role = db.Column(db.String(20), default='user')
        bookings = db.relationship('Booking', backref='user', cascade='all, delete-orphan')

    ER diagram: rectangles entities, lines relationships, PK/FK mark. Schema = yahi structure.
    Tables create: db.create_all() ya migrations. SQLite file SQL viewer se dikha sakte ho.

  13. 13
    Explain where current_user is initialized.
    Times asked 1
    Official solution

    SimpleUserMixin Flask-Login ko batata hai user object kaise treat karna hai (is_authenticated, get_id).

    class User(db.Model, UserMixin):
        id = db.Column(db.Integer, primary_key=True)

    current_user proxy logged-in user. Initialize: login_user(user) / user_loader callback.
    Flask-WTF: Python classes se forms, CSRF, validators. RegisterForm forms.py mein.
    fs_uniquifier Flask-Security mein token/session identity — email change pe sessions invalidate.
    enctype='multipart/form-data' file upload pe zaroori. request.files.get('resume').

  14. 14
    Explain isinstance() where used.
    Times asked 1
    Official solution

    SimpleOOP = objects + classes. Inheritance child parent ke fields/methods reuse karta hai.

    class User(db.Model): ...
    class Admin(User): ...  # model inheritance (joiner ya single table)

    Models inherit db.Model se taaki query/columns milen.

    @staticmethod: self nahi, utility. isinstance(obj, User) type check.

    MAD1 models classes hain, routes functions — mix of OOP + procedural.

  15. 15
    Difference between Authentication and Authorization.
    Times asked 20
    Official solution

    SimpleAuthentication poochta hai "tu kaun hai?", Authorization poochta hai "tujhe yeh kaam karne ki permission hai?"

    Authentication: login. Username + password check karke prove karte ho ki tum genuine user ho. Success pe session/token milta hai.
    Authorization: uske baad role check. Admin hi parking lot delete kar sakta hai, normal user nahi.

    Example (Flask):
    # Authentication

    if user and check_password_hash(user.password, form_password):
        session['user_id'] = user.id
    
    # Authorization
    if session.get('role') != 'admin':
        abort(403)  # logged in ho, lekin allowed nahi

    Project example: student login = authentication. Student admin dashboard nahi khol sakta = authorization.
    Validation alag cheez hai (form sahi bhara hai ya nahi, jaise age 18+).

  16. 16
    Show where Authentication is implemented in your code.
    Times asked 1
    Official solution

    Yeh feature demo hai. Account ready rakho, steps bol ke dikhao.

    Role ke hisaab login → action (create/approve/book) → DB/UI pe result → edge case (fail when slots=0 / blacklisted).
    Do browser windows: admin + user. Search/filter alag se dikhao.
    Agar feature nahi hai to sach bolo aur 2 minute mein kaise add karoge (query + template) explain karo.

  17. 17
    Show where Authorization is implemented in your code.
    Times asked 1
    Official solution

    Yeh feature demo hai. Account ready rakho, steps bol ke dikhao.

    Role ke hisaab login → action (create/approve/book) → DB/UI pe result → edge case (fail when slots=0 / blacklisted).
    Do browser windows: admin + user. Search/filter alag se dikhao.
    Agar feature nahi hai to sach bolo aur 2 minute mein kaise add karoge (query + template) explain karo.

  18. 18
    Add authorization checks to pages/routes.
    Times asked 1
    Official solution

    Yeh project-specific feature add/modify hai. 4 layers touch karo: model, route, template, validation.

    1) Data chahiye to models.py mein column/relationship + DB update (ALTER / migrate / create_all).
    2) Route: GET pe form/page, POST pe request.form se save, flash + redirect.
    3) Template: input name=... Jinja se {{ obj.field }} display.
    4) Rule: duplicate, range, role check backend pe.

    Example naya field 'city':

    user.city = db.Column(db.String(50))
    user.city = request.form.get('city')
    <input name='city'>  ...  {{ user.city }}
  19. 19
    What is Session?
    Times asked 3
    Official solution

    SimpleFlask session request-across data store karta hai, generally signed cookie mein.

    session['user_id'] = user.id
    uid = session.get('user_id')
    session.clear() # logout

    Type: dictionary-like (SecureCookieSession). SECRET_KEY se sign — tamper detect.
    Store kahan: default client cookie. Server-side Redis/filesystem bhi laga sakte ho.
    Browser storage: cookies, localStorage, sessionStorage. Session cookie tab-close pe jaa sakti hai.
    Remember-me: permanent session ya alag token cookie.

  20. 20
    Where are sessions stored?
    Times asked 1
    Official solution

    Definition style question: 1 line simple Hinglish + project example + mini code.

    Template'X ka kaam Y hai. Mere project mein Z jagah use hua.'

    Example'Session login state rakhta hai. session[user_id]=u.id login pe, logout pe session.clear().'

    Agar topic Vue/Celery/Redis ho aur project mein nahi hai to sach bolo, theory example do.

  21. 21
    What happens if the browser/tab is refreshed or reopened?
    Times asked 1
    Official solution

    Definition style question: 1 line simple Hinglish + project example + mini code.

    Template'X ka kaam Y hai. Mere project mein Z jagah use hua.'

    Example'Session login state rakhta hai. session[user_id]=u.id login pe, logout pe session.clear().'

    Agar topic Vue/Celery/Redis ho aur project mein nahi hai to sach bolo, theory example do.

  22. 22
    Explain UserMixin and why it is used.
    Times asked 2
    Official solution

    SimpleUserMixin Flask-Login ko batata hai user object kaise treat karna hai (is_authenticated, get_id).

    class User(db.Model, UserMixin):
        id = db.Column(db.Integer, primary_key=True)

    current_user proxy logged-in user. Initialize: login_user(user) / user_loader callback.
    Flask-WTF: Python classes se forms, CSRF, validators. RegisterForm forms.py mein.
    fs_uniquifier Flask-Security mein token/session identity — email change pe sessions invalidate.
    enctype='multipart/form-data' file upload pe zaroori. request.files.get('resume').

  23. 23
    What is ORM?
    Times asked 49
    Official solution

    SimpleORM = Object Relational Mapping. Database tables ko Python classes/objects se map karta hai, raw SQL kam likhni padti hai.

    Bina ORM: cursor.execute('SELECT * FROM user WHERE id=?', [5])
    ORM se: User.query.get(5) ya db.session.get(User, 5)

    Example model

    class User(db.Model):
        id = db.Column(db.Integer, primary_key=True)
        email = db.Column(db.String(120), unique=True)

    FaydePython mein soch sakte ho, SQL injection se protection (parameterized), relationships easy, DB switch thoda aasan.

    Nuksaancomplex queries slow/abstract, seekhne ki layer extra, kabhi raw SQL phir bhi chahiye.

    MAD1: SQLAlchemy (Flask-SQLAlchemy). Tables db.create_all() ya migrations se banti hain.

  24. 24
    Why did you use (or not use) ORM?
    Times asked 1
    Official solution

    SimpleORM = Object Relational Mapping. Database tables ko Python classes/objects se map karta hai, raw SQL kam likhni padti hai.

    Bina ORM: cursor.execute('SELECT * FROM user WHERE id=?', [5])
    ORM se: User.query.get(5) ya db.session.get(User, 5)

    Example model

    class User(db.Model):
        id = db.Column(db.Integer, primary_key=True)
        email = db.Column(db.String(120), unique=True)

    FaydePython mein soch sakte ho, SQL injection se protection (parameterized), relationships easy, DB switch thoda aasan.

    Nuksaancomplex queries slow/abstract, seekhne ki layer extra, kabhi raw SQL phir bhi chahiye.

    MAD1: SQLAlchemy (Flask-SQLAlchemy). Tables db.create_all() ya migrations se banti hain.

  25. 25
    Explain Cascade Delete.
    Times asked 1
    Official solution

    SimpleCascade parent ke saath child pe automatic action (generally delete).

    Company delete → uski drives bhi delete, warna orphan rows / FK error.
    SQLAlchemy: db.relationship('Drive', cascade='all, delete-orphan', backref='company')
    SQL: ForeignKey(..., ondelete='CASCADE')

    Cascade sirf delete nahi: save-update, merge, refresh-expire, expunge, delete-orphan.
    Cascade Update: parent PK change to child FK update (rare, PK mat badlo).
    Parent delete jab children active hon: constraint error, ya cascade se children gayab, ya pehle children handle karo — design choice examiner poochta hai.
    CSS cascading alag topic hai (styles inherit/override).

  26. 26
    Explain backref and back_populates.
    Times asked 1
    Official solution

    Simpledono SQLAlchemy relationships ko do taraf se connect karte hain, farq sirf likhne ke style ka hai.

    backref: relationship ek side pe likhte ho, doosri side SQLAlchemy khud bana deta hai. Short hai, lekin dono models dekh ke relationship clearly nahi dikhti.

    back_populates: dono models pe relationship explicitly likhte ho. Code padhne wale ko turant samajh aa jaata hai ki User.posts aur Post.author linked hain.

    Example

    class User(db.Model):
        posts = db.relationship('Post', backref='author')

    Yahan Post.author automatically mil jaata hai.

    Explicit version:

    class User(db.Model):
        posts = db.relationship('Post', back_populates='author')
    class Post(db.Model):
        author = db.relationship('User', back_populates='posts')

    Viva tipexaminer ko bolo — MAD1 project mein back_populates zyada clear hai, isliye preferred.

  27. 27
    Difference between backref and back_populates.
    Times asked 10
    Official solution

    Simpledono SQLAlchemy relationships ko do taraf se connect karte hain, farq sirf likhne ke style ka hai.

    backref: relationship ek side pe likhte ho, doosri side SQLAlchemy khud bana deta hai. Short hai, lekin dono models dekh ke relationship clearly nahi dikhti.

    back_populates: dono models pe relationship explicitly likhte ho. Code padhne wale ko turant samajh aa jaata hai ki User.posts aur Post.author linked hain.

    Example

    class User(db.Model):
        posts = db.relationship('Post', backref='author')

    Yahan Post.author automatically mil jaata hai.

    Explicit version:

    class User(db.Model):
        posts = db.relationship('Post', back_populates='author')
    class Post(db.Model):
        author = db.relationship('User', back_populates='posts')

    Viva tipexaminer ko bolo — MAD1 project mein back_populates zyada clear hai, isliye preferred.

  28. 28
    Why did you use uselist? What happens if it is removed?
    Times asked 1
    Official solution

    Definition style question: 1 line simple Hinglish + project example + mini code.

    Template'X ka kaam Y hai. Mere project mein Z jagah use hua.'

    Example'Session login state rakhta hai. session[user_id]=u.id login pe, logout pe session.clear().'

    Agar topic Vue/Celery/Redis ho aur project mein nahi hai to sach bolo, theory example do.

  29. 29
    Explain Primary Key and Foreign Key.
    Times asked 3
    Official solution

    SimplePrimary Key row ki unique ID hai, Foreign Key doosri table ki Primary Key ko point karti hai.

    Primary Key: unique + not null. Har table mein hota hai. Example: user.id = 5
    Foreign Key: relationship banati hai. post.user_id = 5 matlab yeh post user 5 ki hai.

    Example

    class User(db.Model):
        id = db.Column(db.Integer, primary_key=True)
    class Post(db.Model):
        id = db.Column(db.Integer, primary_key=True)
        user_id = db.Column(db.Integer, db.ForeignKey('user.id'))

    FK Primary Key bhi ho sakti hai (1-to-1 profile table). FK unique ho to One-to-One, nahi to One-to-Many.

  30. 30
    What is a Junction Table?
    Times asked 2
    Official solution

    SimpleRelationships tables ko jodti hain taaki related data object se mil jaaye.

    One-to-Many: User → kai Posts. posts = relationship('Post', backref='author'). FK post.user_id.
    One-to-One: User → Profile. uselist=False + unique FK. Profile.user_id unique.
    Many-to-Many: Student ↔ Drive. Junction/secondary table (student_id, drive_id).

    Example 1-1:

    class Profile(db.Model):
        user_id = db.Column(db.Integer, db.ForeignKey('user.id'), unique=True)
        user = db.relationship('User', back_populates='profile', uselist=False)

    1-M ko 1-1: child FK pe unique=True + uselist=False.
    Parent-child: parent PK, child FK. Junction table extra columns bhi rakh sakti hai (applied_on).

  31. 31
    What is a Junction Table?
    Times asked 2
    Official solution

    SimpleRelationships tables ko jodti hain taaki related data object se mil jaaye.

    One-to-Many: User → kai Posts. posts = relationship('Post', backref='author'). FK post.user_id.
    One-to-One: User → Profile. uselist=False + unique FK. Profile.user_id unique.
    Many-to-Many: Student ↔ Drive. Junction/secondary table (student_id, drive_id).

    Example 1-1:

    class Profile(db.Model):
        user_id = db.Column(db.Integer, db.ForeignKey('user.id'), unique=True)
        user = db.relationship('User', back_populates='profile', uselist=False)

    1-M ko 1-1: child FK pe unique=True + uselist=False.
    Parent-child: parent PK, child FK. Junction table extra columns bhi rakh sakti hai (applied_on).

  32. 32
    Explain database relationships.
    Times asked 4
    Official solution

    Examiner code pe ungli rakh ke poochta hai — panic mat karo, 4-line formula bolo.

    1) Yeh file/line kya role hai (model / route / template / config)?
    2) Input kahan se aata hai (form, URL <id>, session, JSON)?
    3) DB pe kya query/write?
    4) Output kya (render_template / redirect / jsonify)?

    Example

    @app.route('/book/<int:id>', methods=['POST']) — logged-in user session se, trek id URL se, Booking add, slots--, redirect history.

    Unknown line: imports (request, url_for, flash), decorators, if checks, commit — har keyword ka reason ready rakho.

  33. 33
    Difference between GET, POST, PUT, and PATCH.
    Times asked 2
    Official solution

    SimpleGET read karta hai, PUT existing resource replace/update karta hai.

    GET /users/1 → data lao, side-effect nahi. PUT /users/1 → poora user update, idempotent.
    PUT vs FETCH: FETCH HTTP method nahi, JS fetch() function hai jo GET/PUT/POST kuch bhi bhej sakta hai.
    Search GET, edit-save PUT/POST. GET se create mat karo.

  34. 34
    Have you used any APIs?
    Times asked 2
    Official solution

    SimpleAPI = Application Programming Interface — do systems predefined rules se baat karti hain. REST API HTTP + JSON use karti hai.

    Controller/route HTML bhi return kar sakta hai. REST API generally JSON return karti hai, frontend alag ho (Vue/Postman).

    Example

    @app.route('/api/users/<int:id>')
    def get_user(id):
        u = User.query.get_or_404(id)
        return jsonify(id=u.id, name=u.name)

    MAD1 HTML apps mein 'API' kabhi-kabhi routes ko hi keh dete hain. Agar Vue nahi to bolo: server-rendered Flask, JSON APIs optional.
    Boolean return: technically jsonify(True) ho sakta hai, lekin meaningful JSON object better. Flask view None return kare to error.
    Test: Postman se GET/POST.
    Parsing: request.get_json() body se, request.args query se.

  35. 35
    What are HTTP Status Codes?
    Times asked 2
    Official solution

    SimpleStatus code number batata hai request ka result.

    200 OK — success, page/data mil gaya.
    201 Created — POST se naya resource.
    302/303 Found/See Other — redirect (login ke baad).
    304 Not Modified — cache use karo.
    400 Bad Request — galat input.
    401 Unauthorized — login nahi (ironically authentication missing).
    403 Forbidden — login hai, permission nahi.
    404 Not Found — route/record nahi.
    500 Internal Server Error — server crash (DB error, NoneType). debug=True pe traceback.
    501 Not Implemented — method server nahi sambhalta.

    abort(404) Flask mein. get_or_404(id) record na ho to 404.
    User ID GET pe exist na kare to 404 return karo, 500 nahi.

  36. 36
    Explain route decorators.
    Times asked 1
    Official solution

    Simple@app.route URL ko Python function se jodta hai. @ wala cheez decorator hai.

    @app.route('/hello/<name>', methods=['GET'])
    def hello(name):
        return f'Hello {name}'

    Decorator function ko wrap karke extra behaviour deta hai (route register, login_required).
    Endpoint generally function name. Path /hello/Ram.
    <int:id> type converter — sirf integer. Bina converter string. ID chahiye to int safer.
    methods=['POST'] only POST. Default GET.
    functools.wraps custom decorator mein original function name/docs preserve karta hai.

  37. 37
    What is Exception Handling?
    Times asked 1
    Official solution

    SimpleException error object. try-except se app crash ki jagah friendly message.

    try:
        age = int(request.form['age'])
        db.session.commit()
    except ValueError:
        flash('Age number hona chahiye')
    except SQLAlchemyError:
        db.session.rollback()
        flash('Database error')

    ArithmeticError/ZeroDivisionError, KeyError, TypeError common. SQLAlchemy type errors: sahi Column type, form ko int() se convert.
    User ko 500 ka traceback mat dikhao production mein.

  38. 38
    Implement exception handling in a route.
    Times asked 1
    Official solution

    SimpleException error object. try-except se app crash ki jagah friendly message.

    try:
        age = int(request.form['age'])
        db.session.commit()
    except ValueError:
        flash('Age number hona chahiye')
    except SQLAlchemyError:
        db.session.rollback()
        flash('Database error')

    ArithmeticError/ZeroDivisionError, KeyError, TypeError common. SQLAlchemy type errors: sahi Column type, form ko int() se convert.
    User ko 500 ka traceback mat dikhao production mein.

  39. 39
    How do you handle runtime errors?
    Times asked 1
    Official solution

    SimpleException error object. try-except se app crash ki jagah friendly message.

    try:
        age = int(request.form['age'])
        db.session.commit()
    except ValueError:
        flash('Age number hona chahiye')
    except SQLAlchemyError:
        db.session.rollback()
        flash('Database error')

    ArithmeticError/ZeroDivisionError, KeyError, TypeError common. SQLAlchemy type errors: sahi Column type, form ko int() se convert.
    User ko 500 ka traceback mat dikhao production mein.

  40. 40
    Add password validation: Confirm Password field. Alphanumeric password. Reject weak passwords.
    Times asked 1
    Official solution

    SimpleValidation galat data rok ti hai — frontend turant, backend must.

    Frontend: required, min='18', maxlength='8', pattern='(?=.*[A-Z]).{8,}'
    Backend example:

    pwd = request.form.get('password','')
    if len(pwd) < 8 or not re.search(r'[A-Z]', pwd) or not re.search(r'[0-9]', pwd):
        flash('Weak password')

    Haan, regex se password rules ho sakte hain.
    Age 18-99, date >= today, slots <= 30 and > 0, confirm password == password, email '@' .
    Duplicate username: User.query.filter_by(email=email).first() or unique=True catch IntegrityError.
    Past date: if date < date.today(): reject. Negative slots: if slots < 0: reject; book pe available > 0 check.

  41. 41
    What happens if a backend route returns nothing?
    Times asked 1
    Official solution

    Definition style question: 1 line simple Hinglish + project example + mini code.

    Template'X ka kaam Y hai. Mere project mein Z jagah use hua.'

    Example'Session login state rakhta hai. session[user_id]=u.id login pe, logout pe session.clear().'

    Agar topic Vue/Celery/Redis ho aur project mein nahi hai to sach bolo, theory example do.

  42. 42
    What is Scaling?
    Times asked 1
    Official solution

    SimpleVertical = same machine ko powerful banao. Horizontal = aur machines add karo.

    Vertical (scale up): RAM/CPU badhao. Simple, lekin ek limit hai, downtime ho sakta hai, single point of failure.
    Horizontal (scale out): 5 servers + load balancer. Sasta long-term, fault tolerant, lekin session/DB sharing sochna padta hai.

    Example10k users aaye to Flask app ke 4 copies chalao nginx peeche, DB alag machine pe.

    Thousands of requests on one machine: caching (Redis), DB indexes, gunicorn workers, phir horizontal.

  43. 43
    Difference between Horizontal Scaling and Vertical Scaling.
    Times asked 3
    Official solution

    SimpleVertical = same machine ko powerful banao. Horizontal = aur machines add karo.

    Vertical (scale up): RAM/CPU badhao. Simple, lekin ek limit hai, downtime ho sakta hai, single point of failure.
    Horizontal (scale out): 5 servers + load balancer. Sasta long-term, fault tolerant, lekin session/DB sharing sochna padta hai.

    Example10k users aaye to Flask app ke 4 copies chalao nginx peeche, DB alag machine pe.

    Thousands of requests on one machine: caching (Redis), DB indexes, gunicorn workers, phir horizontal.

  44. 44
    How would you scale your application for thousands of users?
    Times asked 1
    Official solution

    SimpleVertical = same machine ko powerful banao. Horizontal = aur machines add karo.

    Vertical (scale up): RAM/CPU badhao. Simple, lekin ek limit hai, downtime ho sakta hai, single point of failure.
    Horizontal (scale out): 5 servers + load balancer. Sasta long-term, fault tolerant, lekin session/DB sharing sochna padta hai.

    Example10k users aaye to Flask app ke 4 copies chalao nginx peeche, DB alag machine pe.

    Thousands of requests on one machine: caching (Redis), DB indexes, gunicorn workers, phir horizontal.

  45. 45
    What changes would be needed to handle thousands of requests on a single machine?
    Times asked 1
    Official solution

    Definition style question: 1 line simple Hinglish + project example + mini code.

    Template'X ka kaam Y hai. Mere project mein Z jagah use hua.'

    Example'Session login state rakhta hai. session[user_id]=u.id login pe, logout pe session.clear().'

    Agar topic Vue/Celery/Redis ho aur project mein nahi hai to sach bolo, theory example do.

  46. 46
    Why did you use Bootstrap?
    Times asked 1
    Official solution

    SimpleBootstrap CSS/JS framework — ready classes se responsive UI.

    <button class='btn btn-primary'>Save</button>

    Red button: btn btn-danger. Navbar, cards, grid (row/col).
    CDN: <link href='https://cdn.jsdelivr.net/npm/bootstrap@5...'> — internet na ho to style toot sakti hai. Local copy safer viva ke liye.
    CSS vs Bootstrap: Bootstrap faster consistent UI, custom CSS fine-control. Dono saath use ho sakte hain.
    aria-current='page' accessibility — current nav item screen readers ko.
    CDN fayda: cache, quick setup. Nuksaan: offline, privacy, version lock.

  47. 47
    Show where Bootstrap is included in your project.
    Times asked 1
    Official solution

    SimpleBootstrap CSS/JS framework — ready classes se responsive UI.

    <button class='btn btn-primary'>Save</button>

    Red button: btn btn-danger. Navbar, cards, grid (row/col).
    CDN: <link href='https://cdn.jsdelivr.net/npm/bootstrap@5...'> — internet na ho to style toot sakti hai. Local copy safer viva ke liye.
    CSS vs Bootstrap: Bootstrap faster consistent UI, custom CSS fine-control. Dono saath use ho sakte hain.
    aria-current='page' accessibility — current nav item screen readers ko.
    CDN fayda: cache, quick setup. Nuksaan: offline, privacy, version lock.

  48. 48
    What happens if the Bootstrap CDN is unavailable (no internet)?
    Times asked 1
    Official solution

    SimpleBootstrap CSS/JS framework — ready classes se responsive UI.

    <button class='btn btn-primary'>Save</button>

    Red button: btn btn-danger. Navbar, cards, grid (row/col).
    CDN: <link href='https://cdn.jsdelivr.net/npm/bootstrap@5...'> — internet na ho to style toot sakti hai. Local copy safer viva ke liye.
    CSS vs Bootstrap: Bootstrap faster consistent UI, custom CSS fine-control. Dono saath use ho sakte hain.
    aria-current='page' accessibility — current nav item screen readers ko.
    CDN fayda: cache, quick setup. Nuksaan: offline, privacy, version lock.

  49. 49
    What is DOM?
    Times asked 2
    Official solution

    SimpleDOM = Document Object Model — HTML ka tree jo browser memory mein banata hai. JS isi ko change karta hai.

    document.getElementById('btn').style.color = 'red'
    Jinja server pe HTML banata hai, phir browser DOM parse karta hai. Vue DOM ko reactive update karta hai.

  50. 50
    How can multiple page reloads be prevented?
    Times asked 1
    Official solution

    Definition style question: 1 line simple Hinglish + project example + mini code.

    Template'X ka kaam Y hai. Mere project mein Z jagah use hua.'

    Example'Session login state rakhta hai. session[user_id]=u.id login pe, logout pe session.clear().'

    Agar topic Vue/Celery/Redis ho aur project mein nahi hai to sach bolo, theory example do.

  51. 51
    Change the Navbar color.
    Times asked 1
    Official solution

    Simpleexaminer UI tweak maangta hai — CSS class ya inline, instantly dikhao.

    Button color: <button class='btn btn-success'> ya style='background:#22c55e;color:#fff'
    Navbar: navbar-dark bg-success / style='background:yellow' / fixed-bottom se neeche.
    Center: .wrap { display:flex; justify-content:center; align-items:center; min-height:100vh; }
    text-align:center heading ke liye. Bootstrap: d-flex justify-content-center, mx-auto, text-center.
    Hover: .btn:hover { opacity:0.8; transform:scale(1.02); }
    Half width: class='col-6' ya width:50%. Row→column: flex-direction:column / col-12 stack.
    Login card: card shadow p-4 mx-auto (max-width:400px).
    Table header green: th { background:green; color:white; } Bold column: td:nth-child(2){font-weight:bold}
    Box shadow: box-shadow: 4px 4px 12px rgba(0,0,0,.3);
    Background image: body { background: url('/static/bg.jpg') center/cover; }
    Reset button: <button type='reset'>Clear</button>
    Move button: ms-auto / position / flex order.
    Jinja dashboard heading: <h1>{{ user.name }}'s Dashboard</h1>

  52. 52
    Change the background color.
    Times asked 1
    Official solution

    Simpleexaminer UI tweak maangta hai — CSS class ya inline, instantly dikhao.

    Button color: <button class='btn btn-success'> ya style='background:#22c55e;color:#fff'
    Navbar: navbar-dark bg-success / style='background:yellow' / fixed-bottom se neeche.
    Center: .wrap { display:flex; justify-content:center; align-items:center; min-height:100vh; }
    text-align:center heading ke liye. Bootstrap: d-flex justify-content-center, mx-auto, text-center.
    Hover: .btn:hover { opacity:0.8; transform:scale(1.02); }
    Half width: class='col-6' ya width:50%. Row→column: flex-direction:column / col-12 stack.
    Login card: card shadow p-4 mx-auto (max-width:400px).
    Table header green: th { background:green; color:white; } Bold column: td:nth-child(2){font-weight:bold}
    Box shadow: box-shadow: 4px 4px 12px rgba(0,0,0,.3);
    Background image: body { background: url('/static/bg.jpg') center/cover; }
    Reset button: <button type='reset'>Clear</button>
    Move button: ms-auto / position / flex order.
    Jinja dashboard heading: <h1>{{ user.name }}'s Dashboard</h1>

  53. 53
    Change the Navbar position.
    Times asked 1
    Official solution

    Simpleexaminer UI tweak maangta hai — CSS class ya inline, instantly dikhao.

    Button color: <button class='btn btn-success'> ya style='background:#22c55e;color:#fff'
    Navbar: navbar-dark bg-success / style='background:yellow' / fixed-bottom se neeche.
    Center: .wrap { display:flex; justify-content:center; align-items:center; min-height:100vh; }
    text-align:center heading ke liye. Bootstrap: d-flex justify-content-center, mx-auto, text-center.
    Hover: .btn:hover { opacity:0.8; transform:scale(1.02); }
    Half width: class='col-6' ya width:50%. Row→column: flex-direction:column / col-12 stack.
    Login card: card shadow p-4 mx-auto (max-width:400px).
    Table header green: th { background:green; color:white; } Bold column: td:nth-child(2){font-weight:bold}
    Box shadow: box-shadow: 4px 4px 12px rgba(0,0,0,.3);
    Background image: body { background: url('/static/bg.jpg') center/cover; }
    Reset button: <button type='reset'>Clear</button>
    Move button: ms-auto / position / flex order.
    Jinja dashboard heading: <h1>{{ user.name }}'s Dashboard</h1>

  54. 54
    What is Template Inheritance?
    Times asked 10
    Official solution

    Simpleextends poora layout inherit karta hai, include chhota piece insert karta hai.

    extends: child page base.html ka structure use karti hai, blocks override karti hai. Ek hi parent.
    include: navbar.html / footer.html jahan chaho insert. Kai baar use ho sakta hai.

    base.html:

    {% block content %}{% endblock %}
    
    home.html:
    {% extends 'base.html' %}
    {% block content %}<h1>Home</h1>{% endblock %}
    
    {% include 'navbar.html' %}  → navbar har page pe

    Fayda: header/footer ek jagah, change once — saari pages update. MAD1 mein almost har project use karta hai.

  55. 55
    What is Jinja? Why did you use it?
    Times asked 1
    Official solution

    SimpleJinja2 Flask ka template engine hai. HTML ke andar Python-jaisa data print/loop/if kar sakte ho.

    Bina Jinja har user ke liye alag HTML file. Jinja se ek template + data.

    {{ user.name }} print, {% for x in items %} loop, {% if %} condition, {% extends %} layout.

    Example routereturn render_template('dash.html', treks=treks)

    dash.html: {% for t in treks %}<li>{{ t.name }}</li>{% endfor %}

    HTML files templates/ folder mein isliye kyunki Flask default wahan dhundhta hai. render_template Jinja ko run karta hai.
    Boolean Jinja handle karta hai: {% if user.is_admin %}.

  56. 56
    Did you use AI while building the project?
    Times asked 1
    Official solution

    SimpleSach bolo. AI se boilerplate/docs theek, logic samajh ke explain karo.

    'Boilerplate aur CSS ke liye AI use kiya, models/routes khud design kiye. Report mein X% mention hai.'
    Line-by-line nahi explain kar paoge to examiner pakad lega. Documentation: official Flask/SQLAlchemy + course lectures.

  57. 57
    Where and how did you use AI?
    Times asked 1
    Official solution

    SimpleSach bolo. AI se boilerplate/docs theek, logic samajh ke explain karo.

    'Boilerplate aur CSS ke liye AI use kiya, models/routes khud design kiye. Report mein X% mention hai.'
    Line-by-line nahi explain kar paoge to examiner pakad lega. Documentation: official Flask/SQLAlchemy + course lectures.

Created for educational purposes only. Questions are based on students' personal experiences and may not reflect actual exam content.