+ 5

How do i print "coordinates" at 12 , 8 ?

How do I print "coordinates" at center of page/screen or at 12 , 8 ?

21st May 2017, 7:52 AM
Anil/Anant/1949Nov
Anil/Anant/1949Nov - avatar
3 Réponses
+ 7
see windows.h. I answered a guy here. but i dont think it was what he wanted. It is however what you want I believe. https://www.sololearn.com/discuss/399591/?ref=app
21st May 2017, 7:58 AM
jay
jay - avatar
+ 5
I think it would also be pretty simple to just use loops. I guess it depends on what you prefer, but here's how I'm thinking about your question: int xCoord = 12, yCoord = 8, i; for (i = 0; i < yCoord; i++) { cout << "\n"; } for (i = 0; i < xCoord; i++) { cout << " "; } // whatever you print is now 12 spaces over and 8 lines down
21st May 2017, 3:50 PM
Zeke Williams
Zeke Williams - avatar
+ 3
Thank you Jay n Thank you Zeke.
22nd May 2017, 11:05 AM
Anil/Anant/1949Nov
Anil/Anant/1949Nov - avatar