This commit is contained in:
Lukian LEIZOUR 2023-11-27 16:14:53 +01:00
parent c755619819
commit 63e83a9601
6 changed files with 153 additions and 85 deletions

10
conf.h
View file

@ -16,6 +16,7 @@ typedef struct conf {
typedef struct confList {
struct conf* conf;
int grade;
struct confList* next;
} tConfList;
@ -31,6 +32,7 @@ typedef struct listener {
typedef struct listenerList {
struct listener* listener;
int grade;
struct listenerList* next;
} tListenerList;
@ -47,10 +49,12 @@ int findListenerId(ptListener listenerChain);
ptListener newListenerChain();
void addListener(ptListener listenerChain, int id, char name[], int age, int level);
void removeListener(ptListener listenerChain, int id);
void addConfToConfList(ptConfList confList, ptConf conf);
void addConfToConfList(ptConfList confList, ptConf conf, int grade);
void printConfList(ptConfList confList);
void addListenerToListenerList(ptListenerList listenerList, ptListener listener);
void addListenerToListenerList(ptListenerList listenerList, ptListener listener, int grade);
void printListenerList(ptListenerList listenerList);
void participateToConf(ptConf confChain, ptListener listenerChain, int confId, int listenerId);
void participateToConf(ptConf confChain, ptListener listenerChain, int confId, int listenerId, int grade);
int confGradeAvg(ptConf conf);
int confParticipations(ptConf conf);
#endif // CONF_H