xFactorSchool.com(Beta)
How to Do Examples
Python Examples
HTML Examples
Code Examples
C Code Examples
C++ Code Examples
C# Code Examples
Java Code Examples
Python Code Examples
HTML Code Examples
CSS Code Examples
JavaScript Code Examples
Online Editor
C Code Editor
C++ Code Editor
C# Code Editor
Java Code Editor
Python Code Editor
HTML Code Editor
CSS Code Editor
JavaScript Code Editor
Practice how to create and call a function in C++
C++ Online Editor
Execute Code
More C++ Sample Code
#include <iostream> // the standard input-output stream library, which is necessary for using 'cout' using namespace std; // use std namespace to avoid std:: before cout // Declaring a function void HelloMethod(); int main() { // Calling the function. HelloMethod(); cout << "HelloMethod() function was called" << endl; return 0; } // Defining the function void HelloMethod() { cout << "Hello from HelloMethod" << endl; }