Libft is a project at School 42, where we create our own library of useful functions in C.
This project is aimed at deepening our understanding of the C programming language. Functions developed in this project are analogous to the standard functions in C, and are used in the rest of our projects throughout the School 42 curriculum.
git clone https://github.com/Mr-Galt/libft.git
cd libft
make
This will compile the libft library and create a libft.a
file. You can then link this library to your own C project files while compiling with gcc or cc.
Here are some of the functions I developed for this library:
ft_strlen
: A function to calculate the length of a string.ft_strcpy
: A function to copy a string to another string.ft_strcmp
: A function to compare two strings.ft_atoi
: A function to convert a string to an integer.
(Will list all functions later...)
In addition to the basic functions, I also implemented some bonus functions, such as:
ft_lstnew
: A function to ...ft_lstmap
: A function to ...
(Will list all functions later...)
To test the functions, compile with your files and my libft.a library. For example:
gcc -L. -lft yourfile.c
This will produce a a.out file. Execute it to see the results.
This project was solely developed by myself, but I got help of many very clever friends and students.
This project is licensed under the MIT License.