GS: Hindi / English · Language questions stay in their original language.
120 questions · 120 marks · 2 hours
Choose one option per question.
Tap an option to check it, or open “See answer”.
Correct answer: (B) Media access control sublayer
The functions that depend on the type of medium—access control and framing—are performed by the media access control (MAC) sublayer.
Correct answer: (A) Peer-to-peer
Peer-to-peer is a kind of network, not a topology; ring and bus are topologies.
Correct answer: (D) More than one of the above
Members of a structure are public by default and those of a class private, yet a structure may still have private members—so more than one statement holds.
Correct answer: (A) SMTP client
When a mail server sends mail on to another server, it takes the part of an SMTP client.
Correct answer: (E) None of the above
An IPv6 address is 128 bits long, which is not among the options—so the answer is ‘None of the above’.
Correct answer: (C) To truncate an existing file to zero
ios::trunc wipes the contents of an existing file and truncates its length to zero.
Correct answer: (A) Host-to-host
The host-to-host level of TCP/IP corresponds to the OSI transport layer, and holds TCP and UDP.
Correct answer: (D) More than one of the above
Two or more modes can be combined in open() with |, and ios::in and ios::out are the input and output modes—so more than one statement is correct.
Correct answer: (C) Ping summarizes packet loss and round-trip delay between two IP endpoints.
Ping sends packets and reports the round-trip time and the packets lost; it does not check connectivity at the port level.
Correct answer: (C) int **fun(float *, char **)
The function must take a pointer to float and a pointer to a pointer to char, and return a pointer to a pointer to int—so the declaration is int **fun(float *, char **).
Correct answer: (B) Receiver
In asymmetric key cryptography the public key is given out to all, but the receiver keeps the private key secret.
Correct answer: (C) Segmentation fault
The code calls factorial(a+1), so the recursion never ends and the stack overflows, giving a segmentation fault.
Correct answer: (D) More than one of the above
A pure object-oriented language must support encapsulation, inheritance and polymorphism alike, so more than one option is correct.
Correct answer: (D) More than one of the above
In inheritance the derived class comes first and then the base class with an access specifier; if none is written it is taken as private—so more than one form is correct.
Correct answer: (A) It checks whether the specified variable is an array.
In C++ is_array() checks whether the given variable is an array. It says nothing about the array's dimensions—there are separate means for that.
Correct answer: (A) An object is an instance of its class.
An object is an instance of its class—the class itself is only the blueprint.
Correct answer: (A) By using a pure virtual function in the class
A class is made abstract in C++ by giving it a pure virtual function.
Correct answer: (D) More than one of the above
C++ has both static and dynamic type checking, and member functions may be virtual—so more than one statement is correct.
Correct answer: (A) Encapsulation and inheritance
Data and functions are shut up together within the class—that is encapsulation; and topper is derived from student—that is inheritance. Both features appear.
Correct answer: (B) Silicon
The primary element in computer chips is silicon, a semiconductor and so fit for making circuits.