blob: 1ec9c3d522c695704c00e4cfd59630b10be78ccd (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
|
/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* philo.h :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: dkaiser <dkaiser@student.42heilbronn.de +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2025/01/17 10:23:19 by dkaiser #+# #+# */
/* Updated: 2025/01/17 12:01:01 by dkaiser ### ########.fr */
/* */
/* ************************************************************************** */
#ifndef PHILO_H
# define PHILO_H
# include <unistd.h>
# include <stdlib.h>
# include <stdio.h>
# include <pthread.h>
# include <sys/time.h>
# include "ft_utils.h"
# define ERR_USAGE "Usage: <nbr_of_philos> <ttd> <tte> <tts> [times_must_eat]"
typedef struct s_phdata
{
int nbr_of_philos;
int time_to_die;
int time_to_eat;
int time_to_sleep;
int times_must_eat;
} t_phdata;
#endif
|