Skip to content

Latest commit

 

History

History
39 lines (28 loc) · 1.05 KB

README.md

File metadata and controls

39 lines (28 loc) · 1.05 KB

philosophers (Project from 42 school)

Grade: 100/100

HOW TO USE

1º - Clone the repository

git clone git@github.com:LeRandomJess/philosophers.git

2º - Enter the project folder philo and run make

cd philo
make

3º - Run the program with parameters [number_of_philosophers] [time_to_starve] [time_to_eat] [time_to_sleep] [number_of_times_to_eat]

Time arguments are in miliseconds; [number_of_times_to_eat] is an optional parameter; [number_of_philosophers] shouldn't exceed 200; [time_to_starve] [time_to_eat] and [time_to_sleep] shouldn't be lower than 60;

./philo [number_of_philosophers] [time_to_starve] [time_to_eat] [time_to_sleep] [number_of_times_to_eat]

or

./philo [number_of_philosophers] [time_to_starve] [time_to_eat] [time_to_sleep]

MAKEFILE RULES

make - Compile all files.

make all - Compile all files.

make clean - Delete all .o (object files) files.

make fclean - Delete all .o (object files) and .a (executable) files.

make re - Use rules fclean + all.