Syed Altaf College Massa Kota
Class: 2nd year Paper: Computer Science
TIME: 40 min Name: _______________
1. The logical not operator denoted by ! is a
(a) Unary Operator (b) binary operator (c) Ternary Operator (d) None
2. Comments are used to increase _____________ of the program.
(a) Visibility (b) Beauty (c) Readability (d) Complexity
3. Which term describes the kind of value that a variable can store.
(a) Data Type (b) Variable name (c) Variable type (d) Variable size
4. Which of the following is not arithmetic operator?
(a) + (b) / (c) % (d) >
5. Which operator has the lowest precedence?
(a) ! (b) + (c) = (d) ==
6. An expression that uses the relational operator is known as
(a) Operational (b) Sequence (c) Serial (d) Relational
SHORT QUESTIONS
1. What is variable initialization?
2. What do you know about the term “Keyword”. Discuss it with example?
3. What is variable declaration?
4. What is an Arithematic Expression?
5. What are the uses of operators?
6. What will be the output of the following code?
int a = 3 , b = 3, c;
c = a % b;
printf(“%d”, c);
7. What will be the output of the following code?
int a =9;
b = b % 2;
printf(“%d”, b);
8. What will be the output of the following code?
int number = 6;
int x = 0;
x = --number;
printf(“%d”,x);
9. What will be the output of the following code?
int a = 6;
a ++;
printf(“%d”, a);
10. What will be the output of the following code?
int a = 21;
a = a % 2;
printf(“%d”, a);
LONG QUESTIONS
1. What is a data type? Discuss Integer data type in details with types?
2. What is the identifier? Discuss two types of identifiers used in the C language.
3. What is expression? Discuss it in details?