This repository has been archived on 2024-12-16. You can view files and clone it, but cannot push or open issues or pull requests.
CodeBlocksPortable/WATCOM/samples/clibexam/sleep.c

15 lines
270 B
C

/*
* The following program sleeps for the
* number of seconds specified in argv[1].
*/
#include <stdlib.h>
#include <dos.h>
void main( int argc, char *argv[] )
{
unsigned seconds;
seconds = (unsigned) strtol( argv[1], NULL, 0 );
sleep( seconds );
}