Advertisements
Advertisements
प्रश्न
Consider the following C++ statement. Are they equivalent?
char ch = 67;
char ch = ‘C’;
Advertisements
उत्तर
Both the statements are equivalent as they declare ‘ch’ to be char and initialize it with the value of 67. Since this is the ASCII code for ‘C’, the character constant also can be used to initialize ‘ch’ to 67.
APPEARS IN
संबंधित प्रश्न
Which of the following is a valid string literal?
Write the following real constant into the exponent form:
7.214
Write the following real constant into the exponent form:
0.00005
Assume n = 10; what will be result of n++ and --n;?
Describe the differences between keywords and identifiers?
Is C++ case sensitive? What is meant by the term “case sensitive”?
What is the difference between 56L and 56?
Determine which of the following are valid constant? And specify their type.
‘\t’
Determine which of the following are valid constant? And specify their type.
27,822
How relational operators and logical operators are related to one another?
