Practical List For Sem 1 (RKS)
Practical List For Sem 1 (RKS)
5 Write a C program to enter a distance in to kilometre and convert it in to meter, feet, inches and centimetre
8 Write a C program to find that the accepted number is Negative, or Positive or Zero.
9 Write a program to read marks of a student from keyboard whether the student is pass or fail(using if else)
10 Write a program to read three numbers from keyboard and find out maximum out of these three. (nested if
else)
11 Write a C program to check whether the entered character is capital, small letter, digit or any special
character.
12 Write a program to read marks from keyboard and your program should display equivalent grade according
to following table(if else ladder)
Marks Grade
100 - 80 Distinction
79 - 60 First Class
59 - 40 Second Class
< 40 Fail
15 Write a C program to find out the Maximum and Minimum number from given 10 numbers
16 Write a C program to input an integer number and check the last digit of number is even or odd.
20 Write a program to find out sum of first and last digit of a given number.
21 Write a C program to find the sum and average of different numbers which are accepted by user as many
as user wants
22 Write a program to calculate average and total of 5 students for 3 subjects (use nested for loops)
23 Read five persons height and weight and count the number of person having height greater than 170 and
weight less than 50,
1.
*
**
***
****
2.
*****
****
***
**
*
1.
1
12
123
1234
12345
2.
12345
1234
123
12
1
3
55555
4444
333
22
1
4.
1
22
333
4444
55555
2.
ABCDE
ABCD
ABC
AB
A
32 Write a C program to read and store the roll no and marks of 20 students using array.
33 Write a program to find out which number is even or odd from list of 10 numbers using array
35 Write a C program to calculate the average, geometric and harmonic mean of n elements in an array.
36 Write a program to sort given array in ascending order (Use Insertion sort, Bubble sort, Selection sort,
Mergesort, Quicksort, Heapsort).
44 Write a function Exchange to interchange the values of two variables, say x and y. illustrate the use of this
function in a calling function.
48 Write a function that will scan a character string passed as an argument and convert all lowercase
character into their uppercase equivalents
51 Define structure data type called time_struct containing three member’s integer hour, integer minute and
integer second. Develop a program that would assign values to the individual number and display the time
in the following format: 16: 40:51
52 Define a structure called cricket that will describe the following information:
Player name
Team name
Batting average
Using cricket, declare an array player with 50 elements and write a C program to read the information about
all the 50 players and print team wise list containing names of players with their batting average.
53 Design a structure student_record to contain name, branch and total marks obtained. Develop a program to
read data for 10 students in a class and print them.
56 Write a C program to print the address of character and the character of string using pointer.
60 A file named data contains series of integer numbers. Write a c program to read all numbers from file and
then write all odd numbers into file named “odd” and write all even numbers into file named “even”. Display
all the contents of these file on screen.