GCC Code Coverage Report


Directory: ./
File: lib/my/my_isneg.c
Date: 2024-06-05 00:29:21
Exec Total Coverage
Lines: 5 5 100.0%
Functions: 1 1 100.0%
Branches: 2 2 100.0%

Line Branch Exec Source
1 /*
2 ** EPITECH PROJECT, 2023
3 ** my_isneg
4 ** File description:
5 ** Prints 'P' if the number (n) is positive
6 ** or 'N' if the number (n) is negative
7 */
8
9 #include "my.h"
10
11 2 int my_isneg(int n)
12 {
13
2/2
✓ Branch 0 taken 1 times.
✓ Branch 1 taken 1 times.
2 if (n < 0) {
14 1 my_putchar('N');
15 } else {
16 1 my_putchar('P');
17 }
18 2 return 0;
19 }
20