Skip to content

Commit

Permalink
Solve Interval 2 in c
Browse files Browse the repository at this point in the history
  • Loading branch information
deniscostadsc committed Aug 21, 2024
1 parent c8bbf70 commit b8dd05a
Showing 1 changed file with 22 additions and 0 deletions.
22 changes: 22 additions & 0 deletions solutions/beecrowd/1072/1072.c
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
#include <stdint.h>
#include <stdio.h>

int main() {
int16_t c, n, i = 0, o = 0;

scanf("%d", &c);

while (c--) {
scanf("%d", &n);
if (n > 9 && n < 21) {
i++;
} else {
o++;
}
}

printf("%d in\n", i);
printf("%d out\n", o);

return 0;
}

0 comments on commit b8dd05a

Please sign in to comment.