Practice Exercise #0

Write a C program that calculates the factorial of a non-negative integer and prints the result to the terminal. The integer is provided as a command line argument. Your program, when compiled, should be called "ex0" and an example of how the user should invoke it, and the resulting output, is:

bash$ ls
ex0 ex0.c
bash$ ./ex0 5
120
bash$


Tips: