VOOZH about

URL: https://www.geeksforgeeks.org/c/cleardevice-function-c/

⇱ cleardevice() function in C - GeeksforGeeks


  • Courses
  • Tutorials
  • Interview Prep

cleardevice() function in C

Last Updated : 23 Jan, 2018
The header file graphics.h contains cleardevice() function which clears the screen in graphics mode and sets the current position to (0,0). Clearing the screen consists of filling the screen with current background color. Syntax :
void cleardevice();
Below is the implementation of cleardevice() in C: Output:
On executing the program, the output window looks like :
👁 Image
On pressing any key : 👁 Image
To exit, press any key. 👁 Image
Comment