Thread: timer question

  1. #1
    Registered User dune911's Avatar
    Join Date
    Sep 2001
    Posts
    140

    timer question

    hi there

    i want something like this:

    printf( "print part one" [pause 2 sec] "print part two" );

    my random function is running very well... but now i
    need to put a pause between two text-parts in one part
    of my program.

  2. #2
    Registered User dune911's Avatar
    Join Date
    Sep 2001
    Posts
    140
    umm... will this work?

    printf( "Part 1 \n" );
    sleep(x); // where x=ms
    printf( "Part 2 \n" );

  3. #3
    Its not rocket science vasanth's Avatar
    Join Date
    Jan 2002
    Posts
    1,683

    Here is the reply

    Well you could do this


    printf("First part");
    delay(time); \\ time should be in numbers...
    printf("2nd part");


    or you can also user a for loop to delay the statement..

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. another do while question
    By kbpsu in forum C++ Programming
    Replies: 3
    Last Post: 03-23-2009, 12:14 PM
  2. Timer in Win32
    By nicolas in forum Windows Programming
    Replies: 5
    Last Post: 07-04-2004, 07:21 AM
  3. Question...
    By TechWins in forum A Brief History of Cprogramming.com
    Replies: 16
    Last Post: 07-28-2003, 09:47 PM
  4. opengl DC question
    By SAMSAM in forum Game Programming
    Replies: 6
    Last Post: 02-26-2003, 09:22 PM