MauryaHub PYQ Practice

Programming in C · End Term · Sep 2023 · FN

Programming in C · End Term · Sep 2023 FN

← 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.

0 / 25 published solutions

Question 99 MCQ · 4.0 marks

Source diagram or notation
6406532332819.
Value of a is 30 Value of a is 30
6406532332820.
Value of a is 30 Value of a is 10
6406532332821.
Value of a is 10 Value of a is 10
6406532332822.
Value of a is 10 Value of a is 30

A published solution is not available for this question yet.

Report a correction for Q99

Question 100 MCQ · 4.0 marks

Source diagram or notation
6406532332823.
4
6406532332824.
-1
6406532332825.
8
6406532332826.
36
6406532332827.
6

A published solution is not available for this question yet.

Report a correction for Q100

Question 101 MCQ · 4.0 marks

Source diagram or notation
6406532332832.
Compile Time Error
6406532332833.
3 5
6406532332834.
3 3
6406532332835.
5 3
6406532332836.
5 5

A published solution is not available for this question yet.

Report a correction for Q101

Question 102 MCQ · 4.0 marks

Source diagram or notation
6406532332849.
It incremented the value pointed by ptr by 2.
6406532332850.
It adds 1 to the value pointed to by ptr.
6406532332851.
It modifies the address of ptr.
6406532332852.
It does not modify the value pointed to by ptr.

A published solution is not available for this question yet.

Report a correction for Q102

Question 103 MCQ · 4.0 marks

Consider an integer variable holding a value “0x89209899”. Suppose the available memory addresses are starting from the address “0x128” in a machine, which of the following stores this multibyte data in the little endian way?
6406532332853.Source diagram or notation
6406532332854.Source diagram or notation
6406532332855.Source diagram or notation
6406532332856.Source diagram or notation

A published solution is not available for this question yet.

Report a correction for Q103

Question 104 MCQ · 4.0 marks

Which of the following statements about array initialization in C is correct?
6406532332857.
Arrays can only be initialized at the time of declaration.
6406532332858.
Arrays can be initialized both at the time of declaration and later in the program.
6406532332859.
Arrays can only be initialized with integer values.
6406532332860.
The index of the first element in an array is always 1.

A published solution is not available for this question yet.

Report a correction for Q104

Question 105 MCQ · 4.0 marks

Source diagram or notation
6406532332862.
10
6406532332863.
15
6406532332864.
20
6406532332865.
16

A published solution is not available for this question yet.

Report a correction for Q105

Question 106 MCQ · 4.0 marks

Source diagram or notation
6406532332866.
Matched
6406532332867.
Not Matched
6406532332868.
Compile Time Error
6406532332869.
It generates no output

A published solution is not available for this question yet.

Report a correction for Q106

Question 107 MCQ · 4.0 marks

Source diagram or notation
6406532332870.Source diagram or notation
6406532332871.Source diagram or notation
6406532332872.Source diagram or notation
6406532332873.Source diagram or notation

A published solution is not available for this question yet.

Report a correction for Q107

Question 108 MCQ · 4.0 marks

Source diagram or notation
6406532332874.
3
6406532332875.
6
6406532332876.
7
6406532332877.
4

A published solution is not available for this question yet.

Report a correction for Q108

Question 109 MCQ · 4.0 marks

In a union, how is memory allocated for its members?
6406532332878.
Each member gets its own separate memory space of a fixed, equal size.
6406532332879.
Allocated memory is shared among all members, and the memory size is equal to the size of the largest member.
6406532332880.
Allocated memory is shared among all members, and the memory size is equal to the size of the smallest member.
6406532332881.
The size of the allocated memory is equal to the sum of the sizes of its members.

A published solution is not available for this question yet.

Report a correction for Q109

Question 110 MCQ · 4.0 marks

Source diagram or notation
6406532332882.
A pointer to an integer.
6406532332883.
An array of integers.
6406532332884.
An integer variable.
6406532332885.
A constant integer.

A published solution is not available for this question yet.

Report a correction for Q110

Question 111 MCQ · 4.0 marks

Source diagram or notation
6406532332892.Source diagram or notation
6406532332893.Source diagram or notation
6406532332894.Source diagram or notation
6406532332895.Source diagram or notation

A published solution is not available for this question yet.

Report a correction for Q111

Question 112 MCQ · 4.0 marks

Suppose you open a file in “a” mode, write 10 characters - ABCDEFGHIJ, and close it. You open it again using “w” mode, write 5 characters - KLMNO, and close it. What will be the content of the file when you open it in “r” mode?
6406532332900.
ABCDEFGHIJ
6406532332901.
ABCDE
6406532332902.
ABCDEKLMNO
6406532332903.
ABCDEFGHIJKLMNO
6406532332904.
KLMNO

A published solution is not available for this question yet.

Report a correction for Q112

Question 113 MCQ · 4.0 marks

Source diagram or notation
6406532332905.
FCAF
6406532332906.
FBAF
6406532332907.
FBCF
6406532332908.
FCBF

A published solution is not available for this question yet.

Report a correction for Q113

Question 114 MCQ · 4.0 marks

Source diagram or notation
6406532332909.
22
6406532332910.
54
6406532332911.
15
6406532332912.
20

A published solution is not available for this question yet.

Report a correction for Q114

Question 115 MSQ · 4.0 marks

Which of the following statements is/are true regarding functions in C?
6406532332828.
A function is a block of code, which is only executed when it is invoked.
6406532332829.
A function can be invoked multiple times in the same program.
6406532332830.
A function cannot accept more than 2 parameters.
6406532332831.
A function can not call itself

A published solution is not available for this question yet.

Report a correction for Q115

Question 116 MSQ · 4.0 marks

Which of the following functions computes and returns the factorial of a given positive integer num?
6406532332837.Source diagram or notation
6406532332838.Source diagram or notation
6406532332839.Source diagram or notation
6406532332840.Source diagram or notation

A published solution is not available for this question yet.

Report a correction for Q116

Question 117 MSQ · 4.0 marks

In C, which of the following are valid operations on pointer variables? (Select all that apply)
6406532332841.
Dividing one pointer variable by another pointer variable.
6406532332842.
Comparing two pointers variables for equality.
6406532332843.
Incrementing/Decrementing a pointer variable (e.g. ptr++/ ptr–).
6406532332844.
Multiplying two pointer variables.

A published solution is not available for this question yet.

Report a correction for Q117

Question 118 MSQ · 4.0 marks

Source diagram or notation
6406532332845.Source diagram or notation
6406532332846.Source diagram or notation
6406532332847.Source diagram or notation
6406532332848.Source diagram or notation

A published solution is not available for this question yet.

Report a correction for Q118

Question 119 MSQ · 4.0 marks

Source diagram or notation
6406532332886.
4 bytes
6406532332887.
8 bytes
6406532332888.
16 bytes
6406532332889.
32 bytes
6406532332890.
256 bits
6406532332891.
128 bits

A published solution is not available for this question yet.

Report a correction for Q119

Question 120 MSQ · 4.0 marks

Source diagram or notation
6406532332896.
The function allocates memory for a 2D array at the time of compilation.
6406532332897.
The function dynamically allocates memory for a 2D array.
6406532332898.
The function does not initialize the elements of the 2D array.
6406532332899.
The function initializes all the elements of the 2D array with 0.

A published solution is not available for this question yet.

Report a correction for Q120

Question 121 MSQ · 4.0 marks

Which of the following storage classes initialize a variable with the value 0, if not initialized explicitly?
6406532332913.
auto
6406532332914.
extern
6406532332915.
register
6406532332916.
static

A published solution is not available for this question yet.

Report a correction for Q121

Question 122 NAT · 4.0 marks

Source diagram or notation

A published solution is not available for this question yet.

Report a correction for Q122

Question 123 NAT · 4.0 marks

Source diagram or notation

A published solution is not available for this question yet.

Report a correction for Q123