Objective
Implement a function that scans the first n bytes of a memory area for a given byte and returns a pointer to the first match, or NULL if it is absent.
Steps
$ byte index of memchr("docker", 'r', 6)
5
$ memchr("zsh prompt", 'X', 10)
null
Expected files
Allowed functions
None. Write every helper yourself.
Allowed headers
Standard C library
Implements the contract of a function from the standard C library.

Objective
Implement a function that scans the first n bytes of a memory area for a given byte and returns a pointer to the first match, or NULL if it is absent.
Steps
$ byte index of memchr("docker", 'r', 6)
5
$ memchr("zsh prompt", 'X', 10)
null
Expected files
Allowed functions
None. Write every helper yourself.
Allowed headers
Standard C library
Implements the contract of a function from the standard C library.

Tests
Run the tests to grade your code