07-25-2023, 11:02 AM
Functions can take arguments as input and return values as output.
int square(int num) {
return num * num;
}
int result = square(5);
printf("Result: %d\n", result); // Output: 25
int square(int num) {
return num * num;
}
int result = square(5);
printf("Result: %d\n", result); // Output: 25