Skip to content

R012/C_system_call_examples

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 

Repository files navigation

C_system_call_examples

A repository with a few examples of system calls using C and the UNIX standard libraries

There are two main directories:

  • elementary_sys_calls: a collection of examples involving opening and closing files to read and write in them. Note that these examples are not particularly comprehensive, showing only some basic functionality. Refer to the README file included under this directory for further information.
  • forks: two examples using forks. forks.c is a simple coin-flipping scenario, with a brief explanation of random number generation (RNG) in C and a few samples of bitwise operations in C. forks2.c computes the sum of a set number of factorials, with the intent of displaying how to retrieve and use exit status values generated by child processes.

All examples are created for demonstrative purposes only, and forego best coding practices in the interest of clear presentation. They are, then, not guaranteed to be optimal. Expanding them to parse and interact with console inputs could be an interesting exercise for learners to deepen their understanding of C.

About

A repository with a few examples of system calls using C and the UNIX standard libraries

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors