HELP me find the similar problem

Revision en2, by ultimatechodu.v1, 2024-12-09 16:14:02

I have seen a problem like :
given an array of length n, there is an edge between two elements a[i] and a[j] if lcm(a[i], a[j]) >= some number, or gcd(a[i], a[j]) != 1. Find the number of ways to reach this or something like this. `
Help me find such problems. If there is any tip like how to approach these problems, because I can't store the adjacency list from the array because it would be n * n.

History

 
 
 
 
Revisions
 
 
  Rev. Lang. By When Δ Comment
en2 English ultimatechodu.v1 2024-12-09 16:14:02 76
en1 English ultimatechodu.v1 2024-12-09 16:12:50 374 Initial revision (published)