⟩ If a class contains static variable, then every object of the class has its copy of static variable. a. True b. False
b. False
b. False
What is the output of this program? #include <iostream> using namespace std; template <typename T, int count> void loopIt(T x) { T val[count]; for(int ii = 0; ii < count; ii++) { val[ii] = x++; cout << val[ii] << endl; } }; int main() { float xx = 2.1; loopIt<float, 3>(xx); } a) 2.1 b) 3.1 c) 4.1 d) 2.1 3.1 4.1
Is the size of character literals different in C and C++? a) Implementation defined b) Can't say c) Yes, they are different d) No, they are not different
What is the output of this program? #include <stdio.h> int main() { char a = '12'; printf("%d", a); return 0; } a) Compiler error b) 12 c) 10 d) Empty
Suppose in a hypothetical machine, the size of char is 32 bits. What would sizeof(char) return? a) 4 b) 1 c) Implementation dependent d) Machine dependent
How do we represent a wide character of the form wchar_t? a) L'a' b) l'a' c) L[a] d) la
What will be the output of this program? #include <iostream> using namespace std; int main() { char c = 74; cout << c; return 0; } a) A b) N c) J d) I
Which of the following belongs to the set of character types? a) char b) wchar_t c) only a d) both a and b
Select the right option. Given the variables p, q are of char type and r, s, t are of int type 1. t = (r * s) / (r + s); 2. t = (p * q) / (r + s); a) 1 is true but 2 is false b) 1 is false and 2 is true c) both 1 and 2 are true d) both 1 and 2 are false
How many characters are specified in the ASCII scheme? a) 64 b) 128 c) 256 d) none of the mentioned?
Tell me What is when is dynamic checking necessary?