Skip to content

t0mmusic/ft_printf

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

40 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ft_printf

recreation of the printf function in c

Purpose

This project aims to recreate some of the functionality of the printf function in C. This must be achieved with minimal use of external functions.

%s - print string
%c - print character
%i - print integer
%d - print decimal
%u - print unsigned integer
%x - print lowercase hexidecimal
%X - print uppercase hexidecimal
%p - print pointer in hexidecimal
%% - print %

Bonus

In addition to printing, the function must work with flags and other format specifiers used by the original printf function. The output must be identical to the original function.

'0' flag - fills output string with zeroes
'space' flag - fills output string with spaces
'#' flag - preceeds hexidecimal with '0x'

width specifier - dictates the total length of the output string
precision specifier - limits the total length of the output string

Details

A document detailing some of the choices made can be found here.

Status

Complete! Passes with 125%

About

recreation of the printf function in c

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published