Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 2

THE EDUCATOR SCHOOL

Khayaban-e-Sir Syed, Rawalpindi


Short Questions Series April 2022

Name: ___________ Subject: Computer Science


Grade : 10th Marks: 50

SUBJECTIVE TYPE

Q 1: Answer the following short questions (any 25) (25 x 2 = 50)

Q1) Differentiate between printf() and scanf() functions.


Q2) Why escape sequence is used? Explain with examples.
Q3) Why format specifier is used? Explain with examples.
Q4) Differentiate between constant and variable.
Q5) What is the purpose of header files in C language?
Q6) Why comments are used in programs?
Q7) What is nested selection structure?
Q8) What will be the output of the following code?
char ch;
ch=‘c’;
switch(ch)
{
case ‘a’:
printf(“\n Good Morning! ”);
break;
case ‘b’: printf”\n Have a Nice Day! ”;
break;
case ‘c’:
case ‘d’:
case ‘e’:
printf(“\n Good Bye! ”);
break; }
Q9) Write the following statement using if-else statement.
k = (a+b>20)? a+3*b: a-b;
Q10) What is flowchart?
Q11) What is an Algorithm ?
Q12) Differentiate between syntax and semantic.
Q13) What are reserve words? Why they should not be used as variable names?
Q14) Define Webpage.
Q15) Describe the purpose of Anchor Tag?
Q16) Define a Frameset?
Q17) What is URL?
Q18) Define the properties of truth table.
Q19) What is Karnaugh Map and why it is used`?
Q20) Define Web Hosting?
Q21) Draw and name any three logic gates.
Q22) Write down an algorithm to find factorial of a given number.
Q23) What will be the output of the following code?
Int n;
For(n=30;n>=10;n=n-5)
Printf(“\n%d”,n);
Q24) Write 3 characteristics of High Level languages.
Q25) Difference between loader and debugger?
Q26) Write the following statement using conditional operator.
If (x>y)
z = (x+y)/3;
else
z = x-5*y;
Q27) Construct Truth Table for the following Boolean Expression:
F  x y z  xy z  x y

You might also like