What is the output? 🤔 | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

What is the output? 🤔

//Programa so koja se sobiraat broevite od 1 do 10 #include<iostream> using namespace std; int main() { int n=1; int zbir=0; do { zbir=zbir+n; //zbir+=n; n=n+1; //n+=1; } while (n<=10) cout<<"Zbirot na broevite od 1 do 10 e:"<<zbir<<endl; return 0; }

18th May 2020, 12:22 PM
Mihaela Trencheska
1 Answer
+ 1
the output is”Zbirot na broevite od 1 do 10 e:55” (by the way,do not forget ‘;’ after ‘while(n<=10)’)
19th May 2020, 6:35 AM
Zhengrong Yan
Zhengrong Yan - avatar