public static void main(String args[]){
        
        int matrix[][] = {{1,1,0,1,0},
                          {1,0,0,1,1},
                          {0,0,0,0,0},
                          {1,0,1,0,1},
                          {1,0,0,0,0}
                        };
        NumberOfIsland island = new NumberOfIsland();
        int count = island.numberOfIsland(matrix);
        System.out.println(count);
    }
http://www.geeksforgeeks.org/find-number-of-islands/
src/com/interview/graph/NumberOfIsland.java