why its giving wrong output
Https://ide.codingblocks.com/s/253718
@Aditya-Kushwaha-914550392281281
There are few mistakes in your code
- After printing any element, you also have to print comma (", "). So change line 8,13,18 and 26.
- line 18 should be cout<<a[i][endcol]<<", ";
- line 12 to 29 should be inside while loop. You have write it outside while loop.
@Aditya-Kushwaha-914550392281281
As I can see you got 100 points for this question. Please mark this doubt as resolved.