Simple solution to the skyline problem using a heights arra