You are on page 1of 1

Computer Science (083)

CLASS XI : (2013-14) S.No. 1 2 3

Assignment: Intro to C++ (1)

What are data types supported by C++? What are data type modifiers in c++? Explain any two giving examples. Differentiate between : (a) int a; and unsigned int a; (b)a and a (c) / operator and % operator (d) = and == Arrange the following data types from smallest to largest. Also state how much memory is occupied for storing data of different types given below: float, char, long , double, unsigned int, long double Differentiate between keywords and identifiers giving examples. Segregate valid and invalid identifiers: Marks, MAX, marks2, break, Total Marks, 3score, Daily_weight, %age _MYSCORE, your-score What is preprocessor directive? Explain briefly. What is the purpose of # include directive? Explain giving examples. Why is function main ( ) special? What would happen if main ( ) is not present in the progam ? What do you understand by source code and object code? Evaluate the expressions given below Find out the errors, if any, in the following C++ statements: (i) cout "a =" a ; (ii) m = S,n = 12; 0 = 15 (iii) cout "x" ; x ; (iv) cin y ; j (v) cin "\n" y ; (vi) cout \n "abc" ; Mention the header file required : (a) cin (b)getch() (c) clrscr() (d)cout (e) sqrt() What is the purpose of comments in a program? How single line comments and multiline comments can be given in a C++ program? Give examples.

5 6

7 8 9 10 11 12

13

14

By Nita Arora, PGT Comp. Sc.

You might also like