in turbo c output is not clearing even after including #include<conio.h> and clrscr()

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • bhavanich
    New Member
    • Jan 2013
    • 1

    in turbo c output is not clearing even after including #include<conio.h> and clrscr()

    my first program was to print "welcome" on the screen and the second program was to print "sum of first 10 natural numbers" when i run the first o/p was welcome but when i run the second program o/p was "55lcome" i had included #include<conio. h> and clrscr(); also in my code. Same programs with same software tried in other computer o/p screen was cleared but in my computer it is not the same can anyone help about this......
  • leecorp
    New Member
    • Jan 2013
    • 10

    #2
    The clrscr() is used to Clear the Output screen

    When you call it the Output window Will clear like the cls command in Command Prompt

    But if you put some Printing statements after the clrscr()
    then that will be displayed later on screen

    Look Again
    Have a Nice Day

    Comment

    • swapnali143
      New Member
      • Mar 2012
      • 34

      #3
      if clrscr() is not working then try
      fflush(stdin)

      Syntax for fflush () is
      int fflush ( FILE * stream );

      use stdin it means standard input

      Comment

      Working...