sleep?

This is a discussion on sleep? within the C++ Programming forums, part of the General Programming Boards category; Can I use sleep(); in c++? And if so what header is it in?...

  1. #1
    Unregistered
    Guest

    sleep?

    Can I use sleep(); in c++?
    And if so what header is it in?

  2. #2
    zen
    zen is offline
    of Zen Hall zen's Avatar
    Join Date
    Aug 2001
    Posts
    1,007
    Sleep functions are non-standard. What compiler are you using?
    zen

  3. #3
    Unregistered
    Guest
    borland c++ builder, but im writing an console app.

  4. #4
    Registered User cody's Avatar
    Join Date
    Sep 2001
    Posts
    86

    Re: sleep?

    Aloa he,

    Can I use sleep(); in c++?
    Yes you can.

    And if so what header is it in?
    Well, that depends which OS and compiler you're using.
    For example there is a "Sleep(miliseconds)" function in the
    winbase.h and a sleep(miliseconds) in uhm...damn, forgot the header unter linux ... but there is one

    Greetings
    cody
    #include "reallife.h"

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. [pthread] cancellable sleep in win32?
    By cyberfish in forum C++ Programming
    Replies: 2
    Last Post: 08-11-2007, 03:30 AM
  2. Sleep works with just one thread, but not 2
    By finkus in forum C++ Programming
    Replies: 5
    Last Post: 12-01-2005, 09:17 PM
  3. Problem with Sleep() #$@^#$%^
    By intruder in forum C++ Programming
    Replies: 8
    Last Post: 10-11-2004, 07:46 AM
  4. why do we require sleep?
    By jinx in forum A Brief History of Cprogramming.com
    Replies: 43
    Last Post: 07-14-2004, 09:21 AM
  5. Sleep is overrated...
    By Polymorphic OOP in forum A Brief History of Cprogramming.com
    Replies: 24
    Last Post: 01-24-2003, 12:40 PM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21