K. K. Wagh Polytechnic, Nashik – 3.

Subject: Programming in ‘C’ Sub Code: 9017 Class: FYIF (IF/2/C) Academic Year: 2008 – 2009
Practical No. 10 Understand the concept of user-defined functions: 1. Create a function add( ) which will calculate the sum of the array elements passed as parameters to it. 2. Write a function to calculate the factorial of the number. 3. Create a user defined function to find the minimum value of three float numbers which are passed as the arguments to it. 4. Write a function range( ) which will take value of A and B as parameter and displays total numbers divisible by 3 in the range A to B. 5. Write a function which will take a year as argument and find whether that year is a leap year or not? 6. Create a function to pass any string as argument. This function will find the total number of vowels in that string. Take integer as the return type of the function.

Kute T. B. (Subject Teacher)

CPR – Practical No. 10

Sign up to vote on this title
UsefulNot useful

Master Your Semester with Scribd & The New York Times

Special offer: Get 4 months of Scribd and The New York Times for just $1.87 per week!

Master Your Semester with a Special Offer from Scribd & The New York Times