online compiler and debugger for c/c++

code. compile. run. debug. share.
Source Code   
Language
#include <iostream> #include <cmath> #include <iomanip> #include <limits> using namespace std; double average(double num1, double num2, double num3); int main() { for (int i = 1; i <= 5; i++) { double v1 = rand() % 100 + 1; double v2 = rand() % 100 + 1; double v3 = rand() % 100 + 1; double avg = average(v1, v2, v3); cout << "The average of " << static_cast<int>(v1) << " " << static_cast<int>(v2) << " " << static_cast<int>(v3) << " is: " << fixed << showpoint << setprecision(2) << avg << endl; } return 0; } /// for loop to find the average double average(double num1, double num2, double num3) { double avg = (num1 + num2 + num3) / 3; return avg; }

Compiling Program...

Command line arguments:
Standard Input: Interactive Console Text
×

                

                

Program is not being debugged. Click "Debug" button to start program in debug mode.

#FunctionFile:Line
VariableValue
RegisterValue
ExpressionValue