i don't get all the points where is the wrong ?

This is the problem :
Ariadne wants to find a snail to participate in the World Grand Prix snails. Therefore he asked Pantelis to supply a number of snails after making various measurements should choose one that will participate in the race. The international federation snails racing has divided the races into three levels as follows.
Level 1: Games for snails at speeds up to 10 cm / h.

Level 2: Games for snails at speeds greater than 10 cm / h and less than or equal to 20 cm / h.

Level 3: Matches snails at speeds greater than 20 cm / h.

Pantelis supplies Ariadne N snails every time. Write a program that finds the fastest snail and displays the category in which will take part.

1st line: one integer N (0 <N <1000) corresponding to the number of snails supplying Pantelis Ariadne

2nd line: N integers that correspond to the speed of each snail

And this is my program but i don't get all the points where is the wrong ?
Can anyone help me ?
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
  #include <cmath>
#include <cstdio>
#include <vector>
#include <iostream>
#include <algorithm>
using namespace std;


int main() {

 int num;
 int max = 0;
int a,z;
cin>>num;
if ((num>=0) && (num<=1000)){
 for (int i = 0; i < num; i++) {
cin>>z;

   if (z> max) {
      max = z;

   }
  }
   cout << max << endl;
if (z<=10){
    cout<<1<<endl;
}
else{
 if   ((z>10) && (z<=20))
{
 cout<<2<<endl;
}
else {
    cout<<3<<endl;
}
}
}
else {
    cout<< "wrong number" <<endl;
}


 return 0;
 }

Topic archived. No new replies allowed.