Skip to content

Basic reimplementations of some glibc string-manipulation functions

License

Notifications You must be signed in to change notification settings

fdeage/42-libft

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

42-libft

Overview

This project is a basic reimplementation of some essential glibc functions, without any special tricks.

libft is a first-year project from the 42 school, which I attended in 2013-2016. It abides to the strict rules of 42 not to exceed 5 functions per file, or 25 lines per function.

Getting started

You can compile the project like this:

?> ./make

The code was written with macOS in mind but should work anywhere.

Included functions

Memset, memcpy, etc.

  • memset
  • bzero
  • memcpy
  • memccpy
  • memmove
  • memchr
  • memcmp
  • memdel

String manipulation

  • ft_striter
  • ft_striteri
  • ft_strmap
  • ft_strmapi
  • strnew
  • strdel
  • strclr
  • strequ
  • strnequ
  • strsub
  • strtrim
  • strtrim_mod
  • strsplit
  • strsplit_str
  • strcmp
  • strncmp
  • strrev
  • strlen
  • strpos
  • strcpy
  • strncpy
  • strdup
  • strcat
  • strncat
  • strlcat
  • strjoin
  • strchr
  • strrchr
  • strstr
  • strnstr

Printing

  • putchar
  • putstr
  • putendl
  • putnbr
  • puttab
  • printhex

Color handling

  • putstr_color
  • putstr_color_fd
  • color_switch_fd
  • color_reset_fd

Maths

  • pow_a
  • min
  • max
  • min_float
  • max_float

is_ and to_

  • isalpha

  • isdigit

  • isalnum

  • isascii

  • isprint

  • isspace

  • toupper

  • tolower

  • isnumeric

  • aredigits

Linked list

  • lstnew
  • lstdelone
  • lstdel
  • lstadd
  • lstadd_back
  • lstiter
  • lstmap

Malloc

  • memalloc
  • calloc
  • realloc

Various

  • atoi
  • itoa
  • itoatab
  • qsort
  • swap

42

42 is a French programming school founded in 2013, rooted in P2P collaboration and self-directed learning. Its pedagogy is fully project-based. It is considered a good place to learn to code.

License

This project is licensed under the MIT license.

Author

This project was created by Félix Déage.

About

Basic reimplementations of some glibc string-manipulation functions

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published