Академический Документы
Профессиональный Документы
Культура Документы
1, KALPAKKAM
HALF YEARLY EXAMINATION - 2010-11
COMPUTER SCIENCE
Time : 3 hours
CLASS XI
Max Marks : 70
General Instructions
a) Write proper question number.
b) Answer all the questions.
c) This question paper consists of 3 pages.
d) Indent the programs appropriately
I
1.
2.
3.
4.
5.
6.
II
1
2
3
4
10
1
1
2
2
10
2
2
2
2
2
4
III
1
2
3
4
IV
1
10
2
Page 1
2
3
4
5
6
7
V
1
2
2
2
2
2
2
Gift
Pendrive
Laptop
Printer
Tablet
Wi-fi connection
.
What is the output of the following c++ statements
int a,b,c;
a=35;
b=a%10;
c=b;
b=(a/10)%10;
c=c+b;
cout<<c;
case 'a':
cout<<"Hai ";
break;
Page 2
case "b":
cout<<"sa";
break;
}
}
VI
1
2
3
10
4
4
2
if(i%2==0)
cout<<i+2<<endl;
if(i%3==2)
{
cout<<a<<endl;
a++;
}
a=a+i;
}
VII Answer the following questions
1 Convert the given code to equivalent for loop statement.
a=5;
while(a<25)
{
b=a + 10;
c = c + a;
cout<<b+c;
a++;
}
2 What is the difference between break and continue statement ?
3 Write a program to display the series
1
12
123
1234
or
To generate divisors of a given number.
4 Write a program to find GCD of two numbers with flowchart.
10
2
2
2
***kvgs***
kv1k/kvgs/comp/hy/2010-11
Page 3