Hello, this is which shows how to call functions in c++. Using many functions in a program, lets you divide the work on the code in parts this has a pro because if you mess up during the coding of the function, the error would come up easier.

 

It is possible to call one function form another function (result). For example, if you are calling a function named time () inside of main ()

 

Int main ()

{time (); // This is calling the function time inside of main.

return 0;

}

 

Its is also possible to declare a function before calling it. For example:

 

Void time ()

 

Int main () {

 

            Void ();

}

     Return 0;

}

 

Remember to be careful with the order in coding, because every command has its specific place to be working. Sometimes, the compiler can do its work and display no errors, but don´t be completely sure, because sometimes the compiler may not display any message, but the error may me in the order of the commands.

 

WATCH MY VIDEO  https://youtu.be/9UuwAnWXiig

CC BY 4.0 #Mastery11 – Calling C++ functions by Ricardo Newton is licensed under a Creative Commons Attribution 4.0 International License.