{"id":23605737,"url":"https://github.com/maximegdfr/libft_42","last_synced_at":"2025-07-07T19:36:41.894Z","repository":{"id":269832924,"uuid":"907953365","full_name":"MaximeGDFR/Libft_42","owner":"MaximeGDFR","description":null,"archived":false,"fork":false,"pushed_at":"2025-01-07T18:07:59.000Z","size":52,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-05-17T21:35:13.806Z","etag":null,"topics":["42","42cursus","42projects","42school","c-language","libft","libft42","library"],"latest_commit_sha":null,"homepage":"","language":"C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/MaximeGDFR.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-12-24T17:32:54.000Z","updated_at":"2025-01-07T18:08:02.000Z","dependencies_parsed_at":"2025-02-18T10:47:28.987Z","dependency_job_id":"57c5d49f-baeb-4d2e-af4e-cf7a49cc53cc","html_url":"https://github.com/MaximeGDFR/Libft_42","commit_stats":null,"previous_names":["maximegdfr/libft","maximegdfr/libft_42"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/MaximeGDFR/Libft_42","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MaximeGDFR%2FLibft_42","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MaximeGDFR%2FLibft_42/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MaximeGDFR%2FLibft_42/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MaximeGDFR%2FLibft_42/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/MaximeGDFR","download_url":"https://codeload.github.com/MaximeGDFR/Libft_42/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MaximeGDFR%2FLibft_42/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":264138876,"owners_count":23563239,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["42","42cursus","42projects","42school","c-language","libft","libft42","library"],"created_at":"2024-12-27T13:12:48.746Z","updated_at":"2025-07-07T19:36:41.769Z","avatar_url":"https://github.com/MaximeGDFR.png","language":"C","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Libft - 42 School Project\n\n\u003cdiv id=\"header\" align=\"center\"\u003e\n  \u003cimg src=\"https://github.com/ayogun/42-project-badges/blob/main/badges/libftm.png?raw=true\" width=\"200\"/\u003e\n\u003c/div\u003e\n\nThis repository contains all archives for the project __libft__ in the __42 School Le Havre__ common tree. It's a custom-made library of useful functions in __C language__. The repository includes the `Makefile` and the `libft.h` library.\n\n\u003ch2 align=\"center\"\u003e\n\t\u003ca href=\"#about\"\u003eAbout\u003c/a\u003e\n\t\u003cspan\u003e · \u003c/span\u003e\n\t\u003ca href=\"#index\"\u003eIndex\u003c/a\u003e\n\t\u003cspan\u003e · \u003c/span\u003e\n\t\u003ca href=\"#requirements\"\u003eRequirements\u003c/a\u003e\n\t\u003cspan\u003e · \u003c/span\u003e\n\t\u003ca href=\"#instructions\"\u003eInstructions\u003c/a\u003e\n\t\u003cspan\u003e · \u003c/span\u003e\n\t\u003ca href=\"#testing\"\u003eTesting\u003c/a\u003e\n\u003c/h2\u003e\n\n## About\n\nThis project is a __C library__ of useful functions that are allowed to be used in future __42 School__ projects. Having access to this library will make the coding process in upcoming projects more efficient. The goal of rewriting these functions is to gain a better understanding of them and to build a wide range of utilities for future projects, enabling us to use everything we've coded ourselves.\n\nThe code in this repository follows the rules of the Norminette. 😮‍💨\n\n## Index\n### Functions from `\u003cctype.h\u003e` library\n* [`ft_isascii`](https://github.com/MaximeGDFR/Libft_42/blob/main/ft_isascii.c) - Test a character to see if it's a 7-bit ASCII character.\n* [`ft_isalpha`](https://github.com/MaximeGDFR/Libft_42/blob/main/ft_isalpha.c) - Test a character to see if it's alphabetic.\n* [`ft_isdigit`](https://github.com/MaximeGDFR/Libft_42/blob/main/ft_isdigit.c) - Test a character to see if it's a decimal digit.\n* [`ft_isalnum`](https://github.com/MaximeGDFR/Libft_42/blob/main/ft_isalnum.c) - Test a character to see if it's alphanumeric.\n* [`ft_isprint`](https://github.com/MaximeGDFR/Libft_42/blob/main/ft_isprint.c) - Test a character to see if it's any printable character, including a space.\n* [`ft_tolower`](https://github.com/MaximeGDFR/Libft_42/blob/main/ft_tolower.c) - Convert a character to lowercase.\n* [`ft_toupper`](https://github.com/MaximeGDFR/Libft_42/blob/main/ft_toupper.c) - Convert a character to uppercase.\n\n### Functions from `\u003cstdlib.h\u003e` library\n* [`ft_atoi`](https://github.com/MaximeGDFR/Libft_42/blob/main/ft_atoi.c) - Convert ASCII string to integer.\n* [`ft_calloc`](https://github.com/MaximeGDFR/Libft_42/blob/main/ft_calloc.c) - Allocate space for an array and initializes it to 0. This function and `malloc` return a void pointer, that had no associated data type with it. A void pointer can hold address of any type and can be typecasted to any type.\n\n### Functions from `\u003cstrings.h\u003e` library\n* [`ft_bzero`](https://github.com/MaximeGDFR/Libft_42/blob/main/ft_bzero.c) - Set the first part of an object to null bytes (filling it with zeroes).\n* [`ft_memset`](https://github.com/MaximeGDFR/Libft_42/blob/main/ft_memset.c) - Set memory to a given value.\n* [`ft_memchr`](https://github.com/MaximeGDFR/Libft_42/blob/main/ft_memchr.c) - Find the first occurrence of a character in a buffer (locate byte in byte string).\n* [`ft_memcmp`](https://github.com/MaximeGDFR/Libft_42/blob/main/ft_memcmp.c) - Compare the bytes in two buffers.\n* [`ft_memmove`](https://github.com/MaximeGDFR/Libft_42/blob/main/ft_memmove.c) - Copy bytes from one buffer to another, handling overlapping memory correctly.\n* [`ft_memcpy`](https://github.com/MaximeGDFR/Libft_42/blob/main/ft_memcpy.c) - Copy bytes from one buffer to another.\n\n### Functions from `\u003cstring.h\u003e` library\n* [`ft_strlen`](https://github.com/MaximeGDFR/Libft_42/blob/main/ft_strlen.c) - Get the length of a string.\n* [`ft_strchr`](https://github.com/MaximeGDFR/Libft_42/blob/main/ft_strchr.c) - Find the first occurrence of a character in a string.\n* [`ft_strrchr`](https://github.com/MaximeGDFR/Libft_42/blob/main/ft_strrchr.c) - Find the last occurrence of a character in a string.\n* [`ft_strnstr`](https://github.com/MaximeGDFR/Libft_42/blob/main/ft_strnstr.c) - Locate a substring in a string.\n* [`ft_strncmp`](https://github.com/MaximeGDFR/Libft_42/blob/main/ft_strncmp.c) - Compare two strings, up to a given length.\n* [`ft_strdup`](https://github.com/MaximeGDFR/Libft_42/blob/main/ft_strdup.c) - Create a duplicate of a string, using `malloc`.\n* [`ft_strlcpy`](https://github.com/MaximeGDFR/Libft_42/blob/main/ft_strlcpy.c) - Size-bounded string copy.\n* [`ft_strlcat`](https://github.com/MaximeGDFR/Libft_42/blob/main/ft_strlcat.c) - Size-bounded string concatenation.\n\n### Non-standard functions\n* [`ft_itoa`](https://github.com/MaximeGDFR/Libft_42/blob/main/ft_itoa.c) - Convert integer to ASCII string.\n* [`ft_substr`](https://github.com/MaximeGDFR/Libft_42/blob/main/ft_substr.c) - Get a substring from string.\n* [`ft_strtrim`](https://github.com/MaximeGDFR/Libft_42/blob/main/ft_strtrim.c) - Trim beginning and end of string with the specified substring.\n* [`ft_strjoin`](https://github.com/MaximeGDFR/Libft_42/blob/main/ft_strjoin.c) - Concatenate two strings into a new string, using `calloc`.\n* [`ft_split`](https://github.com/MaximeGDFR/Libft_42/blob/main/ft_split.c) - Split string, with specified character as delimiter, into an array of strings.\n* [`ft_strmapi`](https://github.com/MaximeGDFR/Libft_42/blob/main/ft_strmapi.c) - Create new string from a string modified with a specified function.\n* [`ft_striteri`](https://github.com/MaximeGDFR/Libft_42/blob/main/ft_striteri.c) - Modify a string with a given function.\n* [`ft_putchar_fd`](https://github.com/MaximeGDFR/Libft_42/blob/main/ft_putchar_fd.c) - Output a character to given file.\n* [`ft_putstr_fd`](https://github.com/MaximeGDFR/Libft_42/blob/main/ft_putstr_fd.c) - Output string to given file.\n* [`ft_putendl_fd`](https://github.com/MaximeGDFR/Libft_42/blob/main/ft_putendl_fd.c) - Output string to given file with newline.\n* [`ft_putnbr_fd`](https://github.com/MaximeGDFR/Libft_42/blob/main/ft_putnbr_fd.c) - Output integer to given file.\n\n### Linked list functions *(bonus)*\n* [`ft_lstnew`](https://github.com/MaximeGDFR/Libft_42/blob/main/ft_lstnew.c) - Create new list.\n* [`ft_lstsize`](https://github.com/MaximeGDFR/Libft_42/blob/main/ft_lstsize.c) - Count elements of a list.\n* [`ft_lstlast`](https://github.com/MaximeGDFR/Libft_42/blob/main/ft_lstlast.c) - Find last element of list.\n* [`ft_lstadd_back`](https://github.com/MaximeGDFR/Libft_42/blob/main/ft_lstadd_back.c) - Add new element at end of list.\n* [`ft_lstadd_front`](https://github.com/MaximeGDFR/Libft_42/blob/main/ft_lstadd_front.c) - Add new element at beginning of list.\n* [`ft_lstdelone`](https://github.com/MaximeGDFR/Libft_42/blob/main/ft_lstdelone.c) - Delete element from list.\n* [`ft_lstclear`](https://github.com/MaximeGDFR/Libft_42/blob/main/ft_lstclear.c) - Delete sequence of elements of list from a starting point.\n* [`ft_lstiter`](https://github.com/MaximeGDFR/Libft_42/blob/main/ft_lstiter.c) - Apply function to content of all list's elements.\n* [`ft_lstmap`](https://github.com/MaximeGDFR/Libft_42/blob/main/ft_lstmap.c) - Apply function to content of all list's elements into new list.\n\n## Requirements\nThe library is written in __C language__ and needs the `gcc` compiler, with `\u003cstdlib.h\u003e` and `\u003cunistd.h\u003e` standard libraries to run.\n\n## Instructions\n\n### 1. Compiling the library\n\nTo compile the library, go to its path and run:\n\nFor __basic__ functions:\n```\n$ make\n```\n\nFor __bonus__ functions:\n```\n$ make bonus\n```\n\n### 2. Cleaning all binary (.o) and executable files (.a)\n\nTo delete all files generated with make, go to the path and run:\n```\n$ make fclean\n```\n\n### 3. Using it in your code\n\nTo use the library functions in your code, simply include this header:\n```\n#include \"libft.h\"\n```\n\n## Testing\nThis library have been tested with [Francinette](https://github.com/xicodomingues/francinette).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmaximegdfr%2Flibft_42","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmaximegdfr%2Flibft_42","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmaximegdfr%2Flibft_42/lists"}