July 5, 2021 in C and CPP
int warr[3][2][2] = {1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12}
1.3 int warr[3][2][2] = {1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12};
What will be the value of warr[2][1][0]?
A) 5
B) 7
C) 9
D) 11
July 5, 2021 in C and CPP
1.3 int warr[3][2][2] = {1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12};
What will be the value of warr[2][1][0]?
A) 5
B) 7
C) 9
D) 11
July 5, 2021 in C and CPP
1.2 With every use of memory allocation function, what function should be used to release
allocated memory which is no longer needed?
A) dropmem( )
B) dealloc( )
C) release( )
D) free( )
July 5, 2021 in C and CPP
1.1 int z, x=5, y=-10, a=4, b=2;
z=x++ - --y * b / a;
What will be the final value of z?
A) 5
B) 6
C) 10
D) 11
July 5, 2021 in C and CPP
b) Develop a flowchart and then write a ‘C’ program to add two very large positive integers
using arrays. The maximum number of digits in a number can be 15.
July 5, 2021 in C and CPP
a) Write a recursive function in ‘C’ to count the number of nodes in a singly linked list.
July 5, 2021 in C and CPP
c) Write a ‘C’ function to arrange the elements of an integer array in such a way that all the negative elements are before the positive elements. The array is passed to it as an
argument.
July 5, 2021 in C and CPP
b) Write a ‘C’ function to generate the following figure for n = 7.

The value of n is passed to the function as an argument. Print the triangle only if n is odd
otherwise print an error message.
July 5, 2021 in C and CPP
a) What do you understand by loading and linking of a program?
July 5, 2021 in C and CPP
a) Write a ‘C’ function to reverse a singly linked list by traversing it only once.
b) Write a ‘C’ function to remove those nodes of a singly linked list which have duplicate data. Assume that the linked list is already in ascending order.
July 5, 2021 in C and CPP
a) Define a structure to store roll_no, name and marks of a student.
write a ‘C’ program to create a file “student.dat”. There
must be one record for every student in the file. Accept the data from the user.
write a ‘C’ program to search for the details of the
student whose name is entered by the user.