online compiler and debugger for c/c++

code. compile. run. debug. share.
Source Code   
Language
#include <iostream> using namespace std; int main() { int n, i, v[100], mx, posmx, mn, posmn; cin>>n; for(i=1; i<=n; i++) cin>>v[i]; mx=v[1]; mn=v[1]; posmx=1; posmn=1; for(i=1; i<=n; i++){ if(v[i]>mx){ mx=v[i]; posmx=i; } if(v[i]<mn){ mn=v[i]; posmn=i; } } cout<<"maximul este "<<mx<<endl; cout<<" si ocupa pozitia "<<posmx<<endl; cout<<"minimul este "<<mn<<endl; cout<<" si ocupa pozitia "<<posmn<<endl; return 0; }

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