leetcode

463. Island Perimeter

Solution

Time complexity: O(m n)

Space complexity: O(1)