How to identify function | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

How to identify function

10th Jul 2017, 2:37 PM
vijay
2 Answers
+ 2
function usually has following syntax access_modifier function_name(){ //your code goes here }
10th Jul 2017, 2:40 PM
Мг. Кнап🌠
Мг. Кнап🌠 - avatar
+ 1
eg:- //create function int add (int a) { cout << ++a; return 0; } //using function int main() { add(2); return 0; } //prints 3
10th Jul 2017, 5:22 PM
‎ ‏‏‎Anonymous Guy