You can use system("cls") function with stdlib.h
Not part of the standard library, on some platform it clears the screen.
Hi, Conio.h is a header file which have functions declaration. One of them is clrscr() function. This function have its prototype in conio.h. clrscr() function is used to clear the screen. Thus, whenever u called clrscr() function u r required to define conio.h header file in your program.... Similarly there are many functions in conio.h.... Hope it will help u....
You could manipulate screen's video memory directly in order to achieve that. Video memory address in DOS text mode is allocated on segment 0xB800. Look at the related links section, I've coded an example program for you that uses ClrScr() and ClrScrAsm() functions. Both featuring color support! ;)
use system("clear"); eg: main() { system("clear"); }
'Clearscreen' is not used in C language. TurboC has a clrscr function (prototype in conio.h).
by using "clrscr" command at starting of the program
Function 'clrscr' is not part of the C language. Or the standard libraries. It is MS-DOS specific function, use the help for details (clrscr means clear the screen).
It must be done by a platform-dependent function, it's "clrscr" from conio.h in TurboC
Clearing screen in DEV C++ compiler :#includeint main(){system("cls");}OR: Permanent solution :-Paste the following text in "C:\Dev-Cpp\include\conio.h" of your system#include#includevoid clrscr(){system("cls");}Then you can use clrscr() as a normal built in function under !!!!!!!!!!!
What do you mean by \'alternate function of clrscr\'? A function that undoes clrscr? Or one that fills the screen with random characters? Anyway, clrscr is not part of the standard C library, it is DOS-specific.
Not part of the standard library, on some platform it clears the screen.
Hi, Conio.h is a header file which have functions declaration. One of them is clrscr() function. This function have its prototype in conio.h. clrscr() function is used to clear the screen. Thus, whenever u called clrscr() function u r required to define conio.h header file in your program.... Similarly there are many functions in conio.h.... Hope it will help u....
You could manipulate screen's video memory directly in order to achieve that. Video memory address in DOS text mode is allocated on segment 0xB800. Look at the related links section, I've coded an example program for you that uses ClrScr() and ClrScrAsm() functions. Both featuring color support! ;)
It isn't used. Or at least it shouldn't be used. The clrscr() function is made available through the non-standard header, however not all C implementations support it. The header provides access to console input/output functions that are specifically intended for MS-DOS console applications (and are therefore non-portable), however the header is not defined consistently across all implementations. For instance, Borland (now Embarcadero) provides a clrscr() function via its header but Microsoft does not.The clrscr() function was intended to "clear the screen" which cleared all output from the screen and reset the output cursor to the top-left position ready for new output. These days we don't work with a screen, we work with a "command window", but it's the same thing as far as the clrscr() function is concerned.The reason clrscr() is not a standard function is because console applications don't actually have any need for a clrscr() function. Aside from anything else, it is considered bad form to clear the screen without user-consent. If the user wishes to clear the screen they can simply invoke the CLS command via the DOS command line prior to invoking your program. At least then they have made a conscious decision to clear the screen. However, more importantly, it is never safe to assume that console output is actually being directed to a screen; the user must be free to redirect console output wherever they desire, whether to a disk file, a printer or even as input for another program. A console program that does not allow this freedom of choice is not a console program.Of course there will be cases where a program must use the screen. For instance, a DOS video game wouldn't be much use if the user could redirect output to a printer or a disk file. However, a DOS video game is not a console application and should not be treated as such. Moreover, it is important that the game leave the screen exactly as it found it when the program terminates. These days that is more easily achieved by opening a new window, but in a single-task MS-DOS environment a well-behaved program must save the current console state at runtime and restore that state upon exit.
use system("clear"); eg: main() { system("clear"); }
For computers that have Windows installed, you can use System("CLS"); to clear the screen. This statement calls on the operating system to find the "cls" command and execute it. However, this statement makes your program less portable as it makes it dependent on the Windows OS in order to clear the screen.
'Clearscreen' is not used in C language. TurboC has a clrscr function (prototype in conio.h).