source:
driver/tests/test2.c
@
3134
Last change on this file since 3134 was 2988, checked in by , 8 years ago | |
---|---|
File size: 255 bytes |
Line | |
---|---|
1 | char a[] = {3, 2, 7, -4}; |
2 | char treshold = 4; |
3 | |
4 | int main() { |
5 | char j; |
6 | char *p = a; |
7 | int found = 0; |
8 | for (j=0; j < 4; j++) { |
9 | if (*p <= treshold) { found++; } |
10 | p++; |
11 | } |
12 | return found; |
13 | } |
Note: See TracBrowser
for help on using the repository browser.