Skip to content

A custom C implementation of printf, demonstrating low-level systems programming concepts such as variadic functions, format specifiers, and formatted output processing.

Notifications You must be signed in to change notification settings

gbabohernest/printf

Repository files navigation

0x11. C - printf

Synopsis

This is a simple implementation of the _printf function that formats and prints data

Description

The _printf function produces output according to a format which is described below. This function write its output to the stdout, the standard output stream. Returns the number of characters printed(excluding the null byte used to end output to strings).

  • The available conversion specifiers are:

    • %c: Prints a single character
    • %s: Prints a string of characters.
    • %d: Prints integers.
    • %i: Prints decimal integers.
    • %b: Priints the binary representation of an unsigned decimal.
    • %u: Prints unsigned integers
    • %x: Prints the hexadecimal representation of an unsigned decimal in lowercase letters
    • %X: Prints the hexadecimal representation of an unsigned decimal in uppercase letters
    • %: No argument is converted. The complete conversion specfication is %%
    • %r: Prints a reversed string
    • %R: Prints the Rot13 interpretation of a string

Usage

  • All your files will be compiled on Ubuntu 20.04 LTS
  • Compile using gcc, using the options -Wall -Werror -Wextra -pedantic -std=gnu89
  • Include the "main.h" header file on the functions using _printf

Authors

Acknowledgements

The _printf fucntion emulates functionality of the c standard library function printf This program was written as part of the curriculum for ALX Software Engineering Program. A Full-stack software engineering program that prepares students for careers in the tech industry using project-based peer learning

About

A custom C implementation of printf, demonstrating low-level systems programming concepts such as variadic functions, format specifiers, and formatted output processing.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 2

  •  
  •  

Languages