Corewar documentation 1.0.0
Loading...
Searching...
No Matches
state.c File Reference

The file containing the state functions. More...

Functions

void check_alive_champions (void)
 Check if the champions are alive.
 
void display_winner (node_t *champions)
 Display the winner.
 
int check_champions_number (node_t *champions)
 Check the number of champions.
 

Detailed Description

The file containing the state functions.

Function Documentation

◆ check_alive_champions()

void check_alive_champions ( void )

Check if the champions are alive.

Returns
void

◆ check_champions_number()

int check_champions_number ( node_t * champions)

Check the number of champions.

Parameters
championsThe champions list
Returns
int 1 if the are more than one champion, 0 otherwise

◆ display_winner()

void display_winner ( node_t * champions)

Display the winner.

Parameters
championsThe champions list
Returns
void