answersLogoWhite

0


Best Answer

'Clearscreen' is not used in C language. TurboC has a clrscr function (prototype in conio.h).

User Avatar

Wiki User

13y ago
This answer is:
User Avatar

Add your answer:

Earn +20 pts
Q: Why Clearscreen in c language is used?
Write your answer...
Submit
Still have questions?
magnify glass
imp
Continue Learning about Engineering

How do you use the clearscreen command in Microsoft visual c plus plus 6.0?

There is no such "command" in C++, let alone Visual C++. You are probably referring to the Turbo C++ clearscreen function. It is a 3rd party, user-defined function and is therefore not part of the C++ language itself. You can roll your own clearscreen function, of course. The following is merely an example implementation, but note that this function is not cross-platform compatible because it employs platform-specific code. You will also need platform-specific code to reposition the cursor after clearing the screen. As it stands, the cursor will be positioned 1000 characters from the top left of the console (immediately after the last insertion position). #include<iostream> #include<windows.h> // Non-cross platform, Windows only! void ClearScreen( void ) { HANDLE hConsoleOut; CONSOLE_SCREEN_BUFFER_INFO csbiInfo; DWORD dummy; COORD home = { 0, 0 }; hConsoleOut = GetStdHandle( STD_OUTPUT_HANDLE ); GetConsoleScreenBufferInfo( hConsoleOut, &csbiInfo ); FillConsoleOutputCharacter( hConsoleOut, ' ', csbiInfo.dwSize.X * csbiInfo.dwSize.Y, home, &dummy ); } int main() { // print some garbage: int max=1000; while(max--) std::cout<<rand(); ClearScreen(); }


Why you use C language in electronic engineering?

C is a structured language. Controlled structures used in electronic engineering can be programmed well by C. C++ and C sharp are also used sometimes.


What programming language is used in Pokemon games?

c


What is the difference between c and c plus plus extension?

c language is the structure oriented language and c does not follows the object oriented paradigms . c++ obeys the all object oriented language characteristics ========== C++ is a set of extensions to the C language to allow some (not all) principles of object-oriented programming to be used. Originally, C++ was a front end pre-processor for C and C++ compilers will translate C language functions.


Who are the ancestors of C programming language?

programming languages B and BCPL which was used to derive C

Related questions

How do you use the clearscreen command in Microsoft visual c plus plus 6.0?

There is no such "command" in C++, let alone Visual C++. You are probably referring to the Turbo C++ clearscreen function. It is a 3rd party, user-defined function and is therefore not part of the C++ language itself. You can roll your own clearscreen function, of course. The following is merely an example implementation, but note that this function is not cross-platform compatible because it employs platform-specific code. You will also need platform-specific code to reposition the cursor after clearing the screen. As it stands, the cursor will be positioned 1000 characters from the top left of the console (immediately after the last insertion position). #include<iostream> #include<windows.h> // Non-cross platform, Windows only! void ClearScreen( void ) { HANDLE hConsoleOut; CONSOLE_SCREEN_BUFFER_INFO csbiInfo; DWORD dummy; COORD home = { 0, 0 }; hConsoleOut = GetStdHandle( STD_OUTPUT_HANDLE ); GetConsoleScreenBufferInfo( hConsoleOut, &csbiInfo ); FillConsoleOutputCharacter( hConsoleOut, ' ', csbiInfo.dwSize.X * csbiInfo.dwSize.Y, home, &dummy ); } int main() { // print some garbage: int max=1000; while(max--) std::cout<<rand(); ClearScreen(); }


Which language is used for windowsxp?

Mainly C and C++ and a bit of assembly language.


Which programming language was used to develop tally?

in c language


Why you use C language in electronic engineering?

C is a structured language. Controlled structures used in electronic engineering can be programmed well by C. C++ and C sharp are also used sometimes.


What is C language used for?

Programming.


What is diffence between c and c plus plus?

main difference b/w c and c++ is that c is procedural language whereas c++ is object oriented language also classes are not used in c but in c++ classes are used.


Which language is used for developing windows Operatin system?

C, C++, and C#


Which programming language is used for development of PROE?

c language is used for development of Pro-E


Why c in and c out used in c?

In the programming language C++, cin is used to input the variable and cout is used to print a certain message or result.


Is in is used as a keyword in C language?

Neither "in" nor "is" is a keyword in C.


What is the Difference between C and C languages?

C languages are often based originally on the C language but no longer adhere to it's tenets: often they supersede the original ANSI-92 C language. C++, Objective C, C-, and C# are often used derivatives of the C language. In almost all cases, plain C language can be used with a C language derivative and you get the same result as if you ran it through a plain old C compiler; but the C languages compilers have extra function and procedures available for the programmer.


What language was used to create C?

B