0
Why this code is giving error ?
2 Answers
+ 2
You are using void type for print function so just put
print(n) ;
instead of cout<<print(5); //error
0
Bro just remove the cout << print(5);
And put print(n)
int index = 1;
while (index <= 5){
cout << index << endl;
index ++;
}
either use this code ..