# Kata Task
A bird flying high above a mountain range is able to estimate the height of the highest peak.
Can you?
# Example
## The birds-eye view
^^^^^^
 ^^^^^^^^
  ^^^^^^^
  ^^^^^
  ^^^^^^^^^^^
  ^^^^^^
  ^^^^
## The bird-brain calculations
111111
 1^^^^111
  1^^^^11
  1^^^1
  1^^^^111111
  1^^^11
  1111
111111
 12222111
  12^^211
  12^21
  12^^2111111
  122211
  1111
111111
 12222111
  1233211
  12321
  12332111111
  122211
  1111
`Height = 3`
# Series
* Bird Mountain
* [Bird Mountain - the river](https://www.codewars.com/kata/bird-mountain-the-river)
from collections import Counter

def neigthboors(peaks):
    for x,y in peaks:
        yield x,y-1
        yield x-1,y
        yield x,y
        yield x+1,y
        yield x,y+1       
        
def peak_height(mountain):
    mountain = [(x,y) for y,row in enumerate(mountain) for x,p in enumerate(row)  if p =="^"]
    i = 0
    while mountain:
        mountain = [x_y for x_y, cnt in list(Counter(neigthboors(mountain)).items()) if cnt == 5]
        i+=1
    return i
        
        

from collections import Counter

def neigthboors(peaks):
    for x,y in peaks:
        yield x,y-1
        yield x-1,y
        yield x,y
        yield x+1,y
        yield x,y+1       
        
def peak_height(mountain):
    mountain = [(x,y) for y,row in enumerate(mountain) for x,p in enumerate(row)  if p =="^"]
    i = 0
    while mountain:
        mountain = [x_y for x_y, cnt in list(Counter(neigthboors(mountain)).items()) if cnt == 5]
        i+=1
    return i
        
        
