0% found this document useful (0 votes)
7 views2 pages

C Programming Practical Exercises

The document outlines practical questions for a Computer Science course focusing on C programming. It includes tasks such as calculating currency notes, library fines, prime factors, checking collinearity of points, generating Pascal's triangle, and more. Additionally, it provides guidelines for preparing a practical notebook, including indexing, flowcharts, and program outputs.

Uploaded by

akashrabi108
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
7 views2 pages

C Programming Practical Exercises

The document outlines practical questions for a Computer Science course focusing on C programming. It includes tasks such as calculating currency notes, library fines, prime factors, checking collinearity of points, generating Pascal's triangle, and more. Additionally, it provides guidelines for preparing a practical notebook, including indexing, flowcharts, and program outputs.

Uploaded by

akashrabi108
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd

Jadavpur Vidyapith

Practical Question
Subject: Computer Science
C programming

1. A cashier has currency notes of denominations 10, 20, 50 and 100. If the amount to be
withdrawn is input through the keyboard. Write a c program to find the total number of
currency notes of each denomination the cashier will have to give to the withdrawer.

2. A library charges a fine for every book returned late. Prior to 15 days the late charges for
first 5 days is 50 paise/day, for 6 to 10 days fine is 1 rupee/day and above 10 days fine is
2 rupees/day. If you return the book after 30 days your membership will be cancelled.
Write a program to accept the number of days the member is late to return the book and
display the fine with appropriate message.

3. A positive integer is entered through the keyboard. Write a program in C using function
to obtain the prime factors of this number.

4. Given three points (x1, y1), (x2, y2) and (x3, y3). Write a program to check if all three
points fall on one straight line.
5. write a program to create a pascal triangle.

6. write a program to add first 10 terms of the following series.


1 2 3
+ + +⋯
1! 2! 3!

7. According to study, the approximate level of intelligence of a person can be calculated


using the following formula:
i = 2+(y+0.5x)
Write a program that will produce a table of values of i , y and x. where y varies from 1
to 6, and for each value of y, x varies from 5.5 to 12.5 in steps of 0.5.

8. Write a c program to receive an integer and find its equivalent binary number.

9. write a program to generate all combination of A,B,C,D.


10. write a menu driven program which has the following options.

a. Factorial of a number.
b. Prime or not.
c. Fibonacci Series.
d. Palindrome number check.
e. Exit.

How to prepare practical note book.?


1. Use practical note book.
2. Prepare index.
3. For each program first Write program name or Question.
4. Then Draw the Flowchart or algorithm of the program.
5. Then Write down the C program code.
6. Finally write down the output of the program.

You might also like