0
why canât I call numbers from the user? and I canât use multiple functions... why?
UGHH. Here is an example cout << âGuess a number to end the loop.â << endl; int Getnum() //Sub function { int num; cout << âGive be a number: â; cin >> num; return num; } int main() //main function { do{ num1 = Getnum() num2 = Getnum() // calling function here }while(num1 == 0 || num2 == 0) cout << âGuess right number!â << endl; return 0; }
1 Answer
+ 4
I think this program is not possible on Sololearn because you on SL you have to input all numbers at once (at the beginning).
So you have to use an IDE on your PC.