home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
The C Users' Group Library 1994 August
/
wc-cdrom-cusersgrouplibrary-1994-08.iso
/
listings
/
v_08_11
/
8n11026b
< prev
next >
Wrap
Text File
|
1990-09-18
|
396b
|
23 lines
#include <stdio.h>
#include <stdlib.h>
main()
{
int i = 0;
while (environ[i] != NULL) {
printf("environ[%d] ==> |%s|\n", i, environ[i]);
++i;
}
printf("\nenvironment variable count = %d\n", i);
}
environ[0] ==> |COMSPEC=C:\COMMAND.COM|
environ[1] ==> |PROMPT=$p $g|
environ[2] ==> |PATH=c:\dos;c:\util;|
environ[3] ==> |ABC=def|
environment variable count = 4