Company: Hitachi_13oct
Difficulty: medium
Array Operations: Prime Region Problem Description You are given a 2D array A of numbers having dimensions N x M . Determine how large the biggest cluster of prime numbers is. Note: A region is a group of one or more cells whose values you connect through horizontal, vertical, or diagonal adjacency. Function Description: In the provided code snippet, implement the primeRegion(int N, int M) method. This method should return the size of the largest region that consists only of prime numbers. You can write your code in the space below the phrase "WRITE YOUR LOGIC HERE". There will be multiple test cases running so the input and Output should match exactly as provided. The base output variable result is set to a default value of -404 which can be modified. Additionally, you can add or remove these output variables. Input Format The first line contains 2 space-separated numbers, denoting the dimensions N and M of the 2D array. Each of the following N lines contains M space-separated numbers