MauryaHub PYQ Practice

cs2006_2026T1_Q1_NA.pdf

Application Development - 2(APP DEV-2) · Quiz 1 · Jan 2026

← Course papers · Start practice / exam

Questions and published explanations below are available without starting a test. Some questions may not have a published solution yet.

Question 2 MSQ · 2.0 marks

Which of the following statements about JavaScript scope is/are correct in the browser?
  1. [[IMAGE:ffd929473e8b3cca_3_2]] is function-scoped
    Source diagram or notation
  2. [[IMAGE:ffd929473e8b3cca_3_3]] and [[IMAGE:ffd929473e8b3cca_3_4]] are block-scoped
    Source diagram or notationSource diagram or notation
  3. Variables declared with [[IMAGE:ffd929473e8b3cca_3_5]] are hoisted and initialized with [[IMAGE:ffd929473e8b3cca_3_6]]
    Source diagram or notationSource diagram or notation
  4. [[IMAGE:ffd929473e8b3cca_3_7]] variables can be declared without initialization
    Source diagram or notation
  5. Global variables are always attached to window (as a property)

A published solution is not available for this question yet.

Question 3 MSQ · 2.0 marks

Which of the following statements about JavaScript functions is/are true?
  1. Every function in JavaScript is an object.
  2. Arrow functions have their own **“this”** binding
  3. Function declarations are **hoisted**.
  4. Function expressions assigned to variables are **hoisted** with their function value.

A published solution is not available for this question yet.

Question 4 MCQ · 3.0 marks

Consider the following JavaScript code: [[IMAGE:ffd929473e8b3cca_4_8]] What will be printed on the console?
Source diagram or notation
  1. 20
  2. 10
  3. undefined
  4. 3

A published solution is not available for this question yet.

Question 5 MCQ · 3.0 marks

Consider the following JavaScript code: [[IMAGE:ffd929473e8b3cca_5_9]] The above code is initially loaded in the browser, and then the browser is refreshed **two times**. What will be the final output printed in the console?
Source diagram or notation
  1. [[IMAGE:ffd929473e8b3cca_5_10]]
    Source diagram or notation
  2. [[IMAGE:ffd929473e8b3cca_5_11]]
    Source diagram or notation
  3. [[IMAGE:ffd929473e8b3cca_5_12]]
    Source diagram or notation
  4. [[IMAGE:ffd929473e8b3cca_5_13]]
    Source diagram or notation

A published solution is not available for this question yet.

Question 6 MCQ · 3.0 marks

Match the following storage mechanisms used in the browser with their correct characteristics. [[IMAGE:ffd929473e8b3cca_5_14]] Which of the following is the correct matching?
Source diagram or notation
  1. 1 → B, 2 → C, 3 → A
  2. 1 → B, 2 → A, 3 → C
  3. 1 → A, 2 → C, 3 → B
  4. 1 → B, 2 → C, 3 → D

A published solution is not available for this question yet.

Question 7 MCQ · 3.0 marks

Consider the following Vue application with markup index.html and javascript file app.js. index.html: [[IMAGE:ffd929473e8b3cca_6_15]] app.js: [[IMAGE:ffd929473e8b3cca_7_16]] What will be rendered by the browser **after 4 seconds**?
Source diagram or notationSource diagram or notation
  1. total payable amount is 6000
  2. total payable amount is 8200
  3. total payable amount is 1800
  4. total payable amount is 7800

A published solution is not available for this question yet.

Question 8 MCQ · 3.0 marks

What will be the output of the following program ? [[IMAGE:ffd929473e8b3cca_8_17]]
Source diagram or notation
  1. Undefined
  2. Modern Application Development 2
  3. Will throw syntax error
  4. None of these

A published solution is not available for this question yet.

Question 9 NAT · 3.0 marks

Consider the following JavaScript code snippet: [[IMAGE:ffd929473e8b3cca_8_18]] What is the final value of **x**, logged on the console?
Source diagram or notation

    A published solution is not available for this question yet.

    Question 10 MCQ · 2.0 marks

    Which of the following best describes **UI State (Ephemeral State)** in frontend applications?
    1. It includes all data stored permanently in the database and is shared across users
    2. It represents the complete system data such as users, products, and transactions
    3. It refers to short-lived interface elements like loading indicators or selected tabs
    4. It handles complex application logic and long-term session management

    A published solution is not available for this question yet.

    Question 11 MCQ · 2.0 marks

    Given that HTTP is stateless, which approach is commonly used to manage application state between the client and the server?
    1. Storing all state permanently in frontend memory across sessions
    2. Allowing the frontend to handle complex business logic and data storage
    3. Client or server maintaining state and explicitly exchanging it through requests
    4. Eliminating state entirely from web applications

    A published solution is not available for this question yet.

    Question 12 MCQ · 4.0 marks

    Consider the below Javascript function: [[IMAGE:ffd929473e8b3cca_10_19]] What will be the output of the above program ?
    Source diagram or notation
    1. 1 2 1
    2. 0 0 0
    3. 1 2 3
    4. 0 1 0

    A published solution is not available for this question yet.

    Question 13 MCQ · 5.0 marks

    Consider the following Vue app with html and javascript file given below: File: index.html [[IMAGE:ffd929473e8b3cca_11_20]] File: script.js [[IMAGE:ffd929473e8b3cca_11_21]] What will be rendered on the browser for the code setup given above ?
    Source diagram or notationSource diagram or notation
    1. [[IMAGE:ffd929473e8b3cca_11_22]]
      Source diagram or notation
    2. [[IMAGE:ffd929473e8b3cca_12_23]]
      Source diagram or notation
    3. [[IMAGE:ffd929473e8b3cca_12_24]]
      Source diagram or notation
    4. None of these.

    A published solution is not available for this question yet.

    Question 14 MCQ · 5.0 marks

    Consider the following JavaScript code: [[IMAGE:ffd929473e8b3cca_13_25]] What would be the end result at the end of execution of the code?
    Source diagram or notation
    1. 5
    2. 13
    3. 8
    4. 11

    A published solution is not available for this question yet.

    Question 15 MSQ · 4.0 marks

    Consider the following JavaScript code: [[IMAGE:ffd929473e8b3cca_14_26]] Which of the following statements are TRUE?
    Source diagram or notation
    1. [[IMAGE:ffd929473e8b3cca_14_27]] returns **"Electronic device"**
      Source diagram or notation
    2. [[IMAGE:ffd929473e8b3cca_14_28]] returns **"Samsung is a Electronic device"**
      Source diagram or notation
    3. Calling [[IMAGE:ffd929473e8b3cca_14_29]] throws a runtime error
      Source diagram or notation
    4. [[IMAGE:ffd929473e8b3cca_14_30]] returns **"Electronic device"**
      Source diagram or notation

    A published solution is not available for this question yet.

    Question 16 MCQ · 3.0 marks

    Consider the following HTML and Vue component code carefully and answer the given sub- questions. File: index.html [[IMAGE:ffd929473e8b3cca_15_31]] File: script.js [[IMAGE:ffd929473e8b3cca_15_32]]
    When the [[IMAGE:ffd929473e8b3cca_15_33]] lifecycle hook is invoked, which of the following statements becomes TRUE?
    Source diagram or notationSource diagram or notationSource diagram or notation
    1. The [[IMAGE:ffd929473e8b3cca_15_34]] element exists in the DOM but still contains {{ message }}
      Source diagram or notation
    2. The **DOM** content already reflects the updated value **"Start A"**
    3. The [[IMAGE:ffd929473e8b3cca_15_35]] hook has already executed
      Source diagram or notation
    4. The **DOM** does not exist at all

    A published solution is not available for this question yet.

    Question 17 MCQ · 3.0 marks

    Consider the following HTML and Vue component code carefully and answer the given sub- questions. File: index.html [[IMAGE:ffd929473e8b3cca_15_31]] File: script.js [[IMAGE:ffd929473e8b3cca_15_32]]
    What will be the **final text content displayed in the browser inside the** [[IMAGE:ffd929473e8b3cca_16_36]] **element** after the component is fully mounted and all statements in the [[IMAGE:ffd929473e8b3cca_16_37]] hook have executed?
    Source diagram or notationSource diagram or notationSource diagram or notationSource diagram or notation
    1. [[IMAGE:ffd929473e8b3cca_16_38]]
      Source diagram or notation
    2. [[IMAGE:ffd929473e8b3cca_16_39]]
      Source diagram or notation
    3. [[IMAGE:ffd929473e8b3cca_16_40]]
      Source diagram or notation
    4. [[IMAGE:ffd929473e8b3cca_16_41]]
      Source diagram or notation

    A published solution is not available for this question yet.