Limits 1s, 512 MB

Billy Batson has got the superpower of Shazam recently. By speaking the magic word "Shazam" he can transform himself into a costumed adult with the powers of superhuman.

He doesn’t even know how powerful he is. Every day he is discovering his superpower. Shazam and his friend are giving a serial number of a power when Shazam discovering a new one (the first one is 1, the second one is 2, the third one is 3 and so on).

In a holiday Shazam and his friend have gone for a dinner and discuss his superpowers. Every power of him has not equal strength. Suddenly they notice that the powers have serial numbers divisible by 3 are most powerful than other powers. They called this powers as “Tripplet”. Isn’t it interesting?

Now you will be given serial numbers of N superpower of Shazam. You have to find out how many superpowers are Tripplet or how many of them are divisible by 3 .

Input

The first line contains an integer N (1<=N<=100) – total superpowers of Shazam discovered till now.

Next line contains N integers, each of them is the serial number of superpower of shazam.

Output

Print One integer – The number of “Tripplet”.

Sample

InputOutput
4
1    3    5    6
2

In the sample case, you are given 4 numbers. Among them 3 and 6 are divisible by 3. So the answer will be 2 .

Submit

Login to submit.

Statistics

99% Solution Ratio
joyislam1954Earliest, Oct '18
RUET_SDZFastest, 0.0s
Mili290Lightest, 0 B
Nusab19Shortest, 51B
Toph uses cookies. By continuing you agree to our Cookie Policy.