0% found this document useful (0 votes)
2 views

a3 function

The document outlines a programming lab assignment for GLS University, dated October 18, 2024. It lists 16 tasks that involve writing functions in C, covering basic operations such as addition, factorial calculation, number swapping, and more complex tasks like Fibonacci series and area calculation. Each task focuses on fundamental programming concepts and mathematical operations.

Uploaded by

hinalpatel.8182
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
2 views

a3 function

The document outlines a programming lab assignment for GLS University, dated October 18, 2024. It lists 16 tasks that involve writing functions in C, covering basic operations such as addition, factorial calculation, number swapping, and more complex tasks like Fibonacci series and area calculation. Each task focuses on fundamental programming concepts and mathematical operations.

Uploaded by

hinalpatel.8182
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 1

GLS University

Function task C_programming_lab


18th October’24

1. Write a function to add two integers.


2. Write a function to calculate the factorial of a number.
3. Write a function to swap two numbers using pointers.
4. Write a function to find the greatest of three numbers.
5. Write a function to check if a number is even or odd.
6. Write a function to calculate the area of a circle.
7. Write a recursive function to print Fibonacci series.
8. Write a function to calculate the power of a number (a^b).
9. Write a function to calculate the sum of digits of a number.
10. Write a function to count the number of vowels in a string.
11. Write a function to find the square of a number.
12. Write a function to calculate the cube of a number.
13. Write a function to check if a number is positive, negative, or zero.
14. Write a function to calculate the sum of two floating-point numbers.
15. Write a function to find the average of three integers.
16. Write a function to calculate the difference between two integers.

You might also like