[Solved] Maximum of GCDs January Long 2023 CodeChef
![[Solved] Maximum of GCDs January Long 2023 CodeChef [Solved] Maximum of GCDs January Long 2023 CodeChef](https://realcoder.techss24.com/wp-content/uploads/2023/01/Solved-Maximum-of-GCDs-January-Long-2023-CodeChef.png)
Maximum of GCDs: You are given an array A of N positive integers.The power of a subarray A[L,R] (1≤L≤R≤N) having size (R−L+1) is defined as gcd(AL,A(L+1),…,AR), where gcd denotes the greatest common divisor. Your task is to find the maximum power of a subarray of size k, for all 1≤k≤N. A subarray is formed by deleting some (possibly…