Thứ Hai, 29 tháng 9, 2014

B1 Day 5 (Function)

1. Write a C program that accepts a number and square the number with the help of a function.
To do this,
a. Declare a function.
b. Accept the number.

c. Pass the number to the function and return the square of that number


2. Write a C program to find the area and perimeter of a circle.


3. Write a program with a function that takes two int parameters, adds them together, then returns the sum. The program should ask the user for two numbers, then call the function with the numbers as arguments, and tell the user the sum.



Không có nhận xét nào:

Đăng nhận xét