Playground
#include <iostream> using namespace std; int f1(int &t, int u, int v) { t = t+1; u = u-1; v = v + (t*u); return v; } int main() { int a=3, b=2, c=5; cout << f1(a, b, c) << endl; //pechati '9' //vrednosta na a e promeneta //vrednostite na b i c ostanaa nepromeneti cout << a << " " << b << " " << c << endl; //pechati '4 2 5' return 0; }
Input data
Program output
no input
Execute
Language: ????????? | Memory: ???? KB | Time: ??? ms
Nothing has been executed, yet!