Question: write a c++ program to perform the following function(write the function before main and call them in main) please write the whole code 1. Write
1. Write down the following functions: (a) Compute the factorial of a given integer number. e.g., Factorial (5) should return 120. (b) Find and display all the prime numbers lesser than the given integer number. e.g., Prime (18) should display 2,3,5,7,11,13,17. (c) Compute and return the area of a triangle (dimensions provided thourgh arguments). (d) Compute and return the volume of a cylinder (dimensions through arguments). (e) Compute and return the volume of a cone (dimensions through arguments). (f) Compute and print all the divisors of a given integer (passed to it). (g) Compute and return LCM of two given numbers (passed through arguments). (h) Compute and return HCF of two given numbers (passed through arguments). (i) Compute and return nth element of Fibonacci Series ( n will be provided through arguments) Now write a main() function that tests all the functions using different values
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
