number of processes

¡@

Write a system call, number_of_processes( ),  which a C program can invoke to print out the number of processes existing (regardless their states) in the system.

¡@

ex.

main()

{

int process_count;

.....

process_count = number_of_processes();

printf("There are %d processes currently existing in the system", process_count);

...

}

¡@