-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathfunctions.c
61 lines (41 loc) · 889 Bytes
/
functions.c
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
/*
Functions in C
@author - bhansa
@createdon - 09/07/2017
*/
/*
Functions :
1. return type -
(1)
any_value - int, float, double, long etc.
any_object - array, set, union etc.
(2)
void
2. argument -
(1)
any_value - int, float, double, long etc.
any_object - array, set, union etc.
(2)
void
*/
#include<stdio.h>
// writing function prototypes
void another_function();
int one_more(int value1, int value2, int value3);
int gatsa(){
printf("Hey gatsa\n");
return 500;
}
int main(){
int gatsa_return;
gatsa_return = gatsa();
printf("%d\n",gatsa_return);
another_function();
printf("%d\n", one_more(1, 2, 3));
}
void another_function(){
printf("Just another function\n");
}
int one_more(int value1, int value2, int value3){
return value1 + value2 + value3; //Study about return statements, How they works ??
}