Under construction

Still being built. Things may change

Ice Cream

Interview

Time limit1sMemory limit1024 MB

Summary
Given N serial numbers, find the length of the longest contiguous run of even numbers in the sequence.
Level

Easy2 of 10

Topics
Array, Implementation
Solved
No attempts yet

Problem

Farmer John feeds his cows and plays a small game. He walks down the line of cows and reads the unique serial number on each cow's ear tag (they use ear tags now, not brands). He tries to guess the length of the longest contiguous run of even serial numbers. If he guesses right, he gets extra ice cream after dinner.

Given the number of cows NN (1≤N≤100,0001 \le N \le 100{,}000) and the NN serial numbers, each in the range 1 to 1,000,000, find the length of the longest contiguous run of even serial numbers.

Input

The first line contains one integer NN. Each of the next NN lines contains one integer, the serial number of a cow.

Output

Print one line containing one integer, the length of the longest contiguous run of even serial numbers.

Examples1

  1. Example 1

    Input
    7
    1
    2
    4
    6
    3
    4
    12
    
    Expected output
    3