A simple O(N
2) algorithm can be implemented using two nested loops: in the other one you check if the current item divides
20
and, if the divisibility test passed, you execute the inner one trying to find its companion.
The condition for checking the divisibility is
((20 % arr[i]) == 0)