a.c (285B) [raw]
1 #include <stdio.h> 2 #include <unistd.h> 3 4 int main(void) { 5 int count = 0; 6 int curr; 7 int prev = 0; 8 while(scanf("%d\n", &curr) != EOF) { 9 if (prev && curr > prev) { 10 count++; 11 } 12 prev = curr; 13 } 14 printf("%d\n", count); 15 return 0; 16 }