0

If i dont use #include<conio.h> and use clrscr() and getch() will the program run. If not they why...?

13th Jun 2017, 2:21 PM
Ramya Bali
Ramya Bali - avatar
18 Respostas
+ 15
Clrscr and getch are widely used in non user friendly compliers . In many good compliers you don't have to use them.
13th Jun 2017, 2:36 PM
Prabhu Nithin
Prabhu Nithin - avatar
+ 9
<conio.h> itself belongs to C, and the functions in it are mostly deprecated by newer compilers. Some compilers can still getch(), but not clrscr(). Just try not to touch anything included in the header.
13th Jun 2017, 11:36 PM
Hatsy Rei
Hatsy Rei - avatar
+ 5
The clrscr and getch function are not compulsory. They were simply there to clear the screen each time during output and wait for the users confirmation before exit. These features are now already there in new compilers, so there is absolutely no need for these functions... For example, code::blocks kindly clears the screen before every run, displays the execution time taken by the program, and doesn't exit till the user presses a key...
13th Jun 2017, 2:34 PM
Solo Wanderer 4315
Solo Wanderer 4315 - avatar
+ 5
@Kinshuk: conio.h the header that will not die ;) next will be an influx of questions on turbo c++
13th Jun 2017, 2:50 PM
jay
jay - avatar
+ 4
@Ramya: Which question do you refer to? btw If you are using turbo c++, please upgrade to a newer one. code::blocks -or- visualstudio community edition you will thank yourself later
13th Jun 2017, 2:58 PM
jay
jay - avatar
+ 4
@Ramya Bali Sorry, I got carried away. You see, I don't want people to face the same problems I faced when I was starting this language... Sorry if I was rude...
13th Jun 2017, 3:06 PM
Solo Wanderer 4315
Solo Wanderer 4315 - avatar
+ 3
Yes, the program will work perfectly fine without conio.h, getch or clrscr... This is the 3rd post Im answering recently on conio.h... What has happened to people? https://www.sololearn.com/discuss/458531/?ref=app https://www.sololearn.com/discuss/453557/?ref=app
13th Jun 2017, 2:31 PM
Solo Wanderer 4315
Solo Wanderer 4315 - avatar
+ 3
@Ramya Bali I had posted another answer regarding your query. Did you see that?
13th Jun 2017, 3:01 PM
Solo Wanderer 4315
Solo Wanderer 4315 - avatar
+ 3
@Ramya Bali Im so sorry... Please forgive me... 😞😱🙏
13th Jun 2017, 3:08 PM
Solo Wanderer 4315
Solo Wanderer 4315 - avatar
+ 3
It is a terrible situation though. People teaching 26-30 year old methods.. sorta needs to be addressed
13th Jun 2017, 3:08 PM
jay
jay - avatar
+ 2
@kinshuk and @jay em jst starting to learn this language soo I have question which I ask as a beginner soo plss see that too
13th Jun 2017, 2:54 PM
Ramya Bali
Ramya Bali - avatar
+ 2
thx @jay
13th Jun 2017, 2:58 PM
Ramya Bali
Ramya Bali - avatar
+ 2
u were a lil @kinshuk vasisht but it's OK...â˜ș
13th Jun 2017, 3:07 PM
Ramya Bali
Ramya Bali - avatar
+ 1
yea I did @kinshuk
13th Jun 2017, 3:03 PM
Ramya Bali
Ramya Bali - avatar
+ 1
conio.h clrscr() getch() gotoxy() stdlib.h system("cls") system("pause") here_isnt()
13th Jun 2017, 5:34 PM
Andrés04_ve
Andrés04_ve - avatar
0
Try it in the code playground an see by yourself.
13th Jun 2017, 2:23 PM
Ulisses Cruz
Ulisses Cruz - avatar
0
@Kinshuk Vasisht its OK...â˜ș
13th Jun 2017, 3:11 PM
Ramya Bali
Ramya Bali - avatar