int setActiveElement_LList(LList* myList, const unsigned int index) - AmiralBl3ndic/CLib_v2 GitHub Wiki
- LList* myList: Pointer on any element of the LList
- const unsigned int index: index of the element to set active
-
0: the specified index is not reachable, active element set to last element -
1: everything worked fine, active element set to element n° index
LList* myList = init_LList(8);
setActiveElement_LList(myList, 4); //Returns 1, sets active element to the 5th
setActiveElement_LList(myList, 42); //Returns 0, sets active element to the 8th