For this Question: There are N buildings in a row with different heights H[i] (1 <= i <= N). 

You are standing on the left side of the first building .From this position you can see the roof of a building <b>i</b> if no building to the left of the i<sup>th</sup> building has a height greater than or equal to the height of the  i<sup>th</sup> building.

You are asked to find the number of buildings whose roofs you can see.The first line contains N denoting number of buildings.
The next line contains N space seperated integers denoting heights of the buildings from left to right.


Constraints 
1 <= N <= 100000 
1 <= H[i] <= 1000000000000000The output should contain one integer which is the number of buildings whose  roofs you can see.Sample input: 
5
1 2 2 4 3
 
Sample output:
3

Explanation:-
the building at index 3 will hide before building at index 2 and building at index 5 will hide before building at index 4

Sample input: 
5
1 2 3 4 5
 
Sample output:
5

, I have written this Solution Code: function numberOfRoofs(arr)
  {
      let count=1;
        let max = arr[0];
        for(let i=1;i<arrSize;i++)
        {
            if(arr[i] > max)
            {
                count++;

                max = arr[i];
            }
        }

        return count;      
  }
  , In this Programming Language: JavaScript, Now tell me if this Code is compilable or not?