Hackwithinfy 2021 Solution | N/2 Code

Question: N/2 Code


1. Pick the second most highest element
2. pick the lowest element
3. Find the GCD of the two
4. Take a for loop with n//2 times 
5. Delete elements as two and multiply each GCD with i
6. Take the Sum of it and You will get your answer


Coming Soon.....

Follow Us

You Missed

Leave a Comment

Your email address will not be published. Required fields are marked *