Documente Academic
Documente Profesional
Documente Cultură
5. Display the bill to pay. Raman bought 10 pencils of worth Rs. 25/- and 12 color pens
worth Rs. 24/-
6. Display the bill to pay. Raman bought 10 pencils for Rs 2.50 each and 12 color pens for
Rs. 5 each.
7. Display the bill to pay. Raman bought 10 pencils and 12 color pens.
8. Display the entered hours, minutes and seconds into total seconds.
9. Display the electricity bill to pay on the basis on current and previous reading. Charges
per consumed unit is Rs 3/-.
10. Display the hotel bill to pay on the basis of invited guests. All the guest will have soup,
dinner and desert. 8% sales tax will be imposed on bill.
11. Display the cost of dozen pencils. Cost of 5 pencils is Rs. 12/-
CCED – Centre for Computer Education and Development Phone : 9027763003, 9528416434, 8791601754
CONDITIONS
CCED – Centre for Computer Education and Development Phone : 9027763003, 9528416434, 8791601754
26. Display amount to pay for consumed unit for entered previous and current reading.
[Charge per unit is Rs. 1.30/- per when consumed unit is less than 400 otherwise Rs.
2.50/-]
27. Enter a number and display “Positive” or “Negative” or “Zero” for it.
28. Display amount to pay for consumed unit for entered category, previous and current
reading.
[Category is commercial and units is more than 500, than charge per unit is Rs. 5/-
otherwise Rs. 3.50/-, if category is general and unit is more than 500, than charge per unit is Rs.
3.50/- otherwise Rs. 2/-]
29. Display the amount to pay for consumed unit for entered previous and current reading.
[Charge for first 100 units are Rs. 1.20/-, next 100 units Rs. 2.30/- and for rest Rs. 3.50/-]
30. Display “Even” or “Odd” for entered number.
31. Display “Leap Year” or “Not Leap Year” for entered year.
32. Display “Divisible” or “Not Divisible” for entered number by 3.
33. Display “Divisible” or “Not Divisible” for entered number by 2 and 10 both.
34. Display the division on the basis of given total.
[First -> percentage should be more than equal to 60. Second -> percentage should be in
between 45 and 59. Third -> percentage should be in between 33 and 44. Failed -> percentage
should be less then 33]
35. Display rollno, name, class, total, percentage and division for entered rollno, name,
class and marks of 5 subjects.
36. Display the simple interest for entered principal, interest rate and period.
37. Display menu for
1. Addition
2. Subtraction
3. Multiplication
4. Division
and perform desired action on the entered 2 numbers.
38. Display “Vowel” or “Not Vowel” for entered character.
39. Display total expenditure of party on the basis of invited guests. All the guests will have
coffee, dinner and desert after dinner. If the number guests are more than 100, you can get
discount of 6% on bill. You have to pay 8% tax on Bill.
CCED – Centre for Computer Education and Development Phone : 9027763003, 9528416434, 8791601754
40. Display the state of person on the basis of entered age.
[Child – age between 1-12, Teenager – age between 13-19, Young – age between 20-30,
Mature – age between 31-50, Old – age between 51-75, Too Old – age above 75]
41. A department store places an order to a company for M pieces of electric mixer, N
pieces of toaster and P number of pieces of oven. The discount allowed for various items are
10%, 15% and 12.5% respectively. Company gives 5% discount, if the bill exceeds Rs. 10000/-.
Company charges 11% as sales tax on all items. Display the total amount to pay.
CCED – Centre for Computer Education and Development Phone : 9027763003, 9528416434, 8791601754
LOOP
CCED – Centre for Computer Education and Development Phone : 9027763003, 9528416434, 8791601754
70. Display that given number is Prime or not.
71. Display the greatest number from entered 10 numbers.
72. Display the smallest number from entered 10 numbers.
73. Display the sum of entered 10 numbers.
74. There are 25 students in a class. Enter the gender [G/B] and display the total numbers of
boys and girls.
75. Display menu for
1. Cube
2. Square
3. Factorial
4. Table
and perform desired action for entered a number.
76. Display menu for checking for entered number for Prime, Armstrong, Odd and Even.
77. Display the count of numbers from 1 to 100, which are divisible by 2, 3 and 5.
78. Enter the marks from 1-100 for 25 students and print the number of students.
in the range 0-40
in the range 41-60
in the range 61-80
in the range 81-100.
CCED – Centre for Computer Education and Development Phone : 9027763003, 9528416434, 8791601754
NESTED LOOP
CCED – Centre for Computer Education and Development Phone : 9027763003, 9528416434, 8791601754
* * *
* * * *
* * * * *
92. * * * * *
* * * *
* * *
* *
*
93. Generate
1
0 1
0 1 0
1 0 1 0
1 0 1 0 1
94. Generate 51, 52, 53, 54, 55, 61, 62, 63, 64, 65, 71, 72, 73, 74, 75, 81,
82, 83, 84, 85, 91, 92, 93, 94, 95.
95. Give Result x + x2/2 + x3/3 + x4/4
96. Give Result 1 + x + x2/2 + x3/3 + x4/4
97. Give Result 1/x + 1/x2 + 1/x3 + 1/x4
98. Give Result 1 + 1/x + 1/x2 + 1/x3 + 1/x4
99. Give Result 1 + 1/x + 1/x2 + 1/x3 + 1/x4 + …….. 1/xn
100. Give Result 1 + x + x2/2 + x3/3 + x4/4 + …………. xn/n
101. Generate
1
1 2 1
1 2 3 2 1
1 2 3 4 3 2 1
1 2 3 4 5 4 3 2 1
102. Generate
1
2 1 2
3 2 1 2 3
4 3 2 1 2 3 4
5 4 3 2 1 2 3 4 5
CCED – Centre for Computer Education and Development Phone : 9027763003, 9528416434, 8791601754
103. There are 5 classes having 50 students each. Display the total numbers of boys and girls
for each class and grand total of girls and boys too.
104. Display “Unique Number” or “Not Unique number” for entered number.
[ Digit not repeated ]
105. Display all Prime numbers from 2 to 100.
106. Display all Armstrong numbers from 1 to 1000.
107. Display all Leap Years from 1900 to 2000.
CCED – Centre for Computer Education and Development Phone : 9027763003, 9528416434, 8791601754
STRING MANIPULATION
CCED – Centre for Computer Education and Development Phone : 9027763003, 9528416434, 8791601754
118. Display the entered text into UPPER CASE.
119. Display the entered text into lower case.
120. Display the initial of string in Upper Case:
entered string : viKAs kuMaR sInGh
converted string : V.K.S.
121. Display “Palindrome” or “Not Palindrome” for entered string.
122. Display “Same” or “Different” for entered two strings.
123. Enter first name, middle name and last name. Join them into one string, than display.
124. WAP to extract specified number of characters from left side of entered string and print.
CCED – Centre for Computer Education and Development Phone : 9027763003, 9528416434, 8791601754
ARRAY
125. Display the entered 10 numbers with their grand total.
126. Display the entered 10 numbers along with their average.
127. Display the entered 10 numbers along with smallest number.
128. Display the entered 10 numbers along with greatest number.
129. Display the entered 10 numbers along with greatest and smallest number.
130. Display the average of greatest number of entered array.
131. Display the entered 10 numbers in ascending order.
132. Enter an element in array.
133. Delete an element from an array.
134. Store the sum of 2 arrays of 10 numbers to 3rd array and display all in following format.
[Array1 + Array2 = Array3]
135. Enter numbers in n * n matrix and display it in matrix mode.
136. Enter number in n * n matrix and print the total of each row, each column and each
diagonal.
137. Display the sum of 2, n*n matrices to 3rd matrix.
138. Display the multiplication of 2, n*n matrices to 3rd matrix.
139. Display the Actual and Transposed matrix of n * n.
140. Enter values in two arrays and find their Common in third array.
Ex.
First Array : {2,5,8,10,20}
Second Array : {3,5,8,9,15,20}
Common Array : {5,8,20}
141. There are 4 regions in which there are 5 salesmen, sale products. Enter the quantity of
product sold by each salesman for each region. Display the grand total of sale products for
region and salesman.
142. Enter the record of 5 customers for a bank. [Account no., Customer Name, Balance] and
perform following.
1. Display the report of all customers in formatted way.
2. Display the record of customer for given account number.
3. Make transaction [Deposit/Withdraw]. One can withdraw, when after withdrawal
account has minimum Rs. 500/- left.
4. Exit
CCED – Centre for Computer Education and Development Phone : 9027763003, 9528416434, 8791601754
FUNCTIONS
CCED – Centre for Computer Education and Development Phone : 9027763003, 9528416434, 8791601754
STRUCTURES / CLASS
153. Write function for following and perform selected job from menu for this.
structure student
{ int rno,cl,m1,m2,m3,m4,tot;
char nm[20];
};
1. Get record
2. Calculate total
3. Display record [with percentage and division]
4. Exit
154. Enter record for 10 employees and perform work according to menu.
structure employee
{ int cd,bs;
char nm[20],dpt[30];
};
1. Display all records in report format. [Display Net Salary too. Net Salary is not the
part of record and must be calculated. Net Salary = Basic Salary + 10% of Basic Salary
2. Display records for specified department.
3. Display record for specified code.
4. Make changes for specified code.
5. Exit
155. Enter 10 records of students. Enter Code, Name and Marks of five subjects and prepare
marklist for all, with total, percentage and division.
156. Enter record of 10 trains and prepare time chart. Give the details of enquired train by
train number. Record must consists Train Number, Train Name, Platform Number, Arrival
Time and Departure Time.
CCED – Centre for Computer Education and Development Phone : 9027763003, 9528416434, 8791601754
FILE HANDLING (SINGLE)
CCED – Centre for Computer Education and Development Phone : 9027763003, 9528416434, 8791601754
FILE HANDLING (MULTIPLE)
CCED – Centre for Computer Education and Development Phone : 9027763003, 9528416434, 8791601754