LCM

The first line contains an integer $T$ $(1 \leq T \leq 1000)$, the number of test cases.


This is a companion discussion topic for the original entry at https://toph.co/p/lcm