- Write a program to accept a word of any length and reverse the string.
ICSE computer practical sample paper
Pronic number program
Example 1:
INPUT
Enter
String
school
OUTPUT:
loohcs.
Example 2:
INPUT
Enter
String
papa
OUTPUT:
apap
ICSE computer practical sample paper
2. Design a program to create an array of integers, size should be entered by the user(between 5 to 20). And search a number by any search technique. If the value is not found then print relevant message.
Example 1:
INPUT
Enter
number between 5 to 20
5
Enter
numbers
1,2,3,5,8
Enter
search number:
3
OUTPUT:
Number
found at position 2
Example 2:
INPUT
Enter
number between 5 to 20
8
Enter
numbers
1,2,3,5,8,
13, 67
Enter
search number:
67
OUTPUT:
Number found at position 6
ICSE computer practical sample paper
3. Design a menu driven program, that accepts an integer and displays the following menu :
- displays the sum of the digits of the numbers
- displays whether the number is a special number or not
Example
1:
INPUT
Enter number
1
Enter the number to count the sum of the digits
12
OUTPUT:
Sum of the digits : 3
Example
2:
INPUT
Enter number
2
Enter the number to check for
special number
145
OUTPUT:
It is a special number
4. Write a program to make a pattern
a.
*
* *
* * *
* * * *
* * * * *
b.
12345
1234
123
12
1
ICSE computer practical sample paper