+ 1

the following cpp program if run will produce "compilation error". what's wrong with my code? Please...i'm newbie in programming

https://code.sololearn.com/cNaku72ggDZF/?ref=app

7th Nov 2018, 11:58 AM
Bayu Saputra
Bayu Saputra - avatar
9 Respuestas
+ 8
cin>> NOT cin <<
7th Nov 2018, 12:27 PM
Izaak GOLDSTEIN
Izaak GOLDSTEIN - avatar
+ 7
You have to use >> operator with cin object and NOT <<
7th Nov 2018, 12:00 PM
KrOW
KrOW - avatar
+ 7
Hi Bayu, you forget to increment the loop counter <n1> in the while loop, you should change the code, as in its current state the loop is infinite.
7th Nov 2018, 2:57 PM
Ipang
+ 7
You missed semicolon in line no 24
8th Nov 2018, 4:56 AM
Shreyansh
Shreyansh - avatar
+ 6
Remove semicolon from line 25
8th Nov 2018, 7:45 AM
Shreyansh
Shreyansh - avatar
+ 4
Sama2 Bayu, ini output yg diinginkan seperti apa yach, saya msh belum paham, mungkin saya bisa bantu sedikit.
7th Nov 2018, 11:08 PM
Ipang
+ 3
Thank's for kroW and Goldstein..
7th Nov 2018, 2:04 PM
Bayu Saputra
Bayu Saputra - avatar
+ 3
Shreyansh Sinha : thank you Ipang : saya menginginkan output menampilkan suku ke-1, suku ke-2, .... , suku ke-n (n sesuai yg diinput user)..kira2 kode pengulangannya bagaimana,mas?
8th Nov 2018, 11:14 AM
Bayu Saputra
Bayu Saputra - avatar
+ 2
Terima kasih, mas ipang... waktu saya coba, pengulangannya tidak sesuai yang saya harapkan.
7th Nov 2018, 10:47 PM
Bayu Saputra
Bayu Saputra - avatar