This repo contains a reimplementation of the standard C printf function. It is part of the 42 common core curriculum. It handles the following specifiers: %c, %s, %p, %d, %i, %u, %x, %X, %%, and the following flags: ., #, space, +, -, 0.
N/A = undefined behavior, sp = space.
- | . | 0 | sp | + | # | |
---|---|---|---|---|---|---|
di | Y | Y | Y | Y | Y | N/A |
u | Y | Y | Y | N/A | N/A | N/A |
xX | Y | Y | Y | N/A | N/A | prefix 0x/0X |
p | Y | N/A | N/A | N/A | N/A | N/A |
cs | Y | Y | N/A | N/A | N/A | N/A |
- '-' overrides '0' if both are used.
- '+' overrides ' ' if both are used.
This project is licensed under the MIT License.
Darren Kuro – darrenkuro@icloud.com
GitHub: @darrenkuro