Header Ads Widget

Ticker

6/recent/ticker-posts

Computer Programming With C Practicals (PPS)

 LIST OF PRACTICALS

Sr.Practical TitleAnswer
1Write a program to that performs as calculator ( addition, multiplication, division, subtraction).Solution
2Write a program to find area of triangle(a=h*b*.5)
a = area
h = height
b = base

Write a program to calculate simple interest (i = (p*r*n)/100 )
i = Simple interest
p = Principal amount
r = Rate of interest
n = Number of years
Solution
3Write a C program to enter a distance in to kilometre and convert it in to meter, feet, inches and centimetre.
Write a program to compute Fahrenheit from centigrade (f=1.8*c +32)
Write a C program to read a number and check it is even or odd.
Solution
4Write a C program to find that the accepted number is Negative, or Positive or Zero. Write a program to read three numbers from keyboard and find out maximum out of these three. (nested if else) Write a C program to check whether the entered character is capital, small letter, digit or any special characterSolution
5Write 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

Write a C program demonstrate functionality of calculator using switch-case. Write a C program to find factorial of a given number.
Solution
6Write a program to reverse a number.
Write a program to generate first n number of Fibonacci series.
Write a C program to find the sum and average of different numbers which are accepted by user as many as user wants.
Write a program to check whether the given number is prime or not
Solution
7Write a program to evaluate the series 1^2+2^2+3^2+……+n^2
Write a C program to find 1+1/2!+1/3!+1/4!+.....+1/n!.
Write a C program to display following patterns using asterisk (*).

1.

*
**
***
****

2.
*****
****
***
**
*


Write a C program to display following patterns. 

1.                    
12345
1234
123
12
1

2.
AAAAA
AAAA
AAA
AA
A

3.
1
0 1
1 0 1
0 1 0 1
1 0 1 0 1

Solution
8Write a program to read array of integers and print it in reverse order.
Write a program that adds two 1-dimensional array & store into third array.
Write a program to insert and delete an element to/from desired position in an array. Write a program to sort a given array in ascending order. (use Bubble Sort algorithm)
Solution
9Write a program for multiplication of two matrices.
Write a program to find length of string without using library function.
Write a program to concatenate two strings without using library function
Solution
10Write a program that reads a string and counts occurrences of a given character. Write a program convert character into Toggle character.
Write a program that checks whether the string is palindrome or not using string library function.
Solution
11Write a C Program to demonstrate the use of inbuilt string functions.
Write a function power that computes x raised to the power y for integer x and y and returns double type value.
Write a calculator program (add, subtract, multiply, divide). Prepare user defined function for each functionality
Solution
12Write a program to find sum of elements of 1-D Array using Function.
Write a program that use user defined function swap() to interchange the value of two variable.
Write a program to find factorial of a number using recursion.
Write a program to generate Fibonacci series using recursion
Solution
13Write a function which takes a two integer array as argument and give sum of these arrays. Define a structure to enter enrolment number, name of student and marks of the student in three subjects. Enter data for 5 students. Display grade cards of all students. Display student who has top rank in the class.
Define a structure called cricket that will describe the following information: Player name, Team name, Batting average Declare an array player.
Write a program to print name & team of those players whose batting average is greater than given value
Solution
14Write a program to demonstrate the concept of union.
Write a program using pointer and function to determine the length of string.
Write a program to demonstrate the concept of pointer.
Write a program to add elements of array using pointer.
Solution
15Write a program to copy the content one file into another file.
Write a program to demonstrate ftell() and fseek() for file handling.
Write a program that compares two files and returns 0 if they are equal and 1 if they are not.
Solution

Post a Comment

0 Comments