Sie sind auf Seite 1von 5

What is Character Set? (2) What is a token? (2) What are identifiers? (2) What is a stream?

(2) What is the size of following example of string literals? Marks (2) What are Binary Operators? (2) Give any 2 examples of Unary Operators. (2) What does return0; indicate? (2) Why is include <iostream.h> written with all programmes? (2) Name two basic streams of c++. (2) How are single line and multiline block comments written? (2) Define a variable? (2) What does intmain()standfor? (2) What do you mean by IDE? (2) What is the role of a compiler? (2) List any 4 common program errors. (2) What are logical errors? (2) What are cascading input and output operators? (2) What is the use of a Comma, and a Semicolon ; ? (2) What is equal to = sign used for?

(2) Give three Bitwise operators. (2) What does cerr indicate? (2) What is code generation? (3) Point out the errors in the following program. (3) include<iostream.h> int main() { cout<<findme; return0 } Write cout and cin statements to enter a number and then display the number entered. (3) What is C++ Character set? (3) What are keywords? (3) What are Literals? (3) Write a short note on Hexadecimal Integer constants? (3) What are Syntax Errors and Semantic errors? (5) List the tokens in C++. (5) Explain Integer constants along with their rule? (5) What is (a) Character Constant and (b) StringLiteral? (5) Explain the following PunctuatorsParenthesis, Brackets, Asterisk, Ellipsis, Pound Sign (5) Name any five binary operators? (5) What are Semantic Errors and Type errors?

(5) What kinds of constants are the following? 14,011,0X2A,17,014,0XBC1 What will be the sizes of the following constants: x, y, Guneet, s , ? Find the syntax error in the following code: main() { int a,b: cin>>a>>b; cout<<a+b, return0 } Explain the following types of errors: Syntax error, Semantic error and Type error State the reason why the code given below is illegal. And how can we correct it? main() { inti=j=k=0; } Write a C++ program that inputs a students marks in three subjects and prints the average marks. Find errors in the following code: int main() { cout<<Enternumber; cin>>num sqr=num*num cout<<the square is<<sqr; } In C++, give the predefined objects for input, output and

error. What do you mean by cascading output operator and cascading input operator? Arrange the following in the order of their precedence: << >> < <= > >= + - * / % && What are the advantages of cout and cin over printf() and scanf()? Do the following code segments perform the same job: int a=10; int a(10); Are the given statements same? enum grade g; grade g; What does the modulo operator% do? What is the result of the expression22.6 % 5.2? Given the following two definitions: Unsigned int x1=0, x2=0; What will be the result of each of the following expressions? (a) x1&&x2 (b) x1||x2 Why should we avoid equality comparisons between floating point numbers? What is the value of expression!(1&&0||!1). Why should we avoid comparing signed and unsigned values? Given the following code fragment int marks=20; cout<<++marks<<n; cout<<marks<<n;

(i)What output does the above code fragment produce? (ii)What is the effect of replacing ++marks with marks+ +? (iii)What is the effect of replacing ++marks with marks+1? What is the difference between runtime error and syntax error? What do you understand by code generation? What is the condition that every C++ program must fulfill? Following are some of the real constants in exponent form. Choose the invalid form. 152E05,1.52E07,.25E-7,1520E04 Explain the terms :tokens, keywords and identifiers.

Das könnte Ihnen auch gefallen