IN101 project on Conway's Game of Life
Functions
linked_list_cell.c File Reference

Source code for a linked list implementation. More...

#include "linked_list_cell.h"
Include dependency graph for linked_list_cell.c:

Functions

linked_cell linked_list_get (linked_list list, int idx)
 Get a cell from a linked list by its index. More...
 
bool linked_cell_smaller (linked_list cell1, linked_list cell2)
 
void linked_list_insert_unsorted (linked_list *p_list, int row, int column)
 Insert an element into a linked list, at the first position. More...
 
void linked_list_insert (linked_list *p_list, int row, int column)
 Insert an element into a linked list, sorted by row and column. More...
 
void linked_list_delete (linked_list *p_list, int row, int column)
 Delete an element from a linked list. More...
 
void linked_list_free (linked_list list)
 Free a linked list from memory. More...
 

Detailed Description

Source code for a linked list implementation.

Author
Victor Colomb (vic.c.nosp@m.ol@h.nosp@m.otmai.nosp@m.l.fr)
Date
2021-03-06

Function Documentation

◆ linked_list_delete()

void linked_list_delete ( linked_list p_list,
int  row,
int  column 
)

Delete an element from a linked list.

Parameters
p_listpointer to a linked list
idx
Precondition
idx has to be inferior to the number of cells in the list

◆ linked_list_free()

void linked_list_free ( linked_list  list)

Free a linked list from memory.

Parameters
list

◆ linked_list_get()

linked_cell linked_list_get ( linked_list  list,
int  idx 
)

Get a cell from a linked list by its index.

Parameters
list
idx
Precondition
idx has to be inferior to the number of cells in the list
Returns
linked_cell of the given index

◆ linked_list_insert()

void linked_list_insert ( linked_list p_list,
int  row,
int  column 
)

Insert an element into a linked list, sorted by row and column.

Parameters
p_listpointer to a linked list
row
column

◆ linked_list_insert_unsorted()

void linked_list_insert_unsorted ( linked_list p_list,
int  row,
int  column 
)

Insert an element into a linked list, at the first position.

Parameters
p_listpointer to a linked list
row
column