Tag: programming languages

Questions Related to programming languages

C++

  1. True

  2. False

  3. It depends on the variable type

  4. None of the Above


Correct Option: C

C++

  1. sin()

  2. kbhit()

  3. tmpnam()

  4. None of the Above


Correct Option: B
  1. char *a=new char[20];

  2. char a=new char[20];

  3. char a=new char(20.0);

  4. None of the Above


Correct Option: A
  1. class aClass{public:int x;};

  2. /* A comment */

  3. char x=12;

  4. None of the Above


Correct Option: A
  1. int main()

  2. int main(int argc, char *argv[])

  3. They both work

  4. None of the Above


Correct Option: C
  1. True

  2. False

  3. Invalid Statement

  4. None of the Above


Correct Option: A
  1. The snippet is illegal

  2. It loops forever

  3. It is ignored by compiler, but it is not illegal

  4. None of the Above


Correct Option: B

C++

  1. Constructor

  2. Destructor

  3. Constitutor

  4. None of the Above


Correct Option: A

C++

  1. 1

  2. 0

  3. Code cannot compile

  4. None of the Above


Correct Option: B
  1. 6

  2. 38

  3. An unlimited number

  4. None of the Above


Correct Option: A