#include <stdio.h>
#include <errno.h>
#include <string.h>
void perror(char const *s)
{
int errno_copy = errno;
if(s != NULL) {
fputs(s, stderr);
fputs(": ", stderr);
}
fputs(strerror(errno_copy), stderr);
fputc('\n', stderr);