Problems
In a country of Unlearned Lessons 2
In a country of Unlearned Lessons 2
\includegraphics{https://static.e-olymp.com/content/6b/6bff6a309fa0b0edfe5c15a1eaff34d396375c61.jpg}
Victor has a program that helps him to find quickly \textbf{GCD} of many numbers. Therefore, the guard decided to change the rules: now Victor must find the greatest common divisor (\textbf{GCD}) of the numbers on the interval $[l; r]$, and the guards must find the least common multiple (\textbf{LCM}). Who gets the less number that wins.
\InputFile
The first line contains the number of elements $n\:(1 \le n \le 10^6)$ in array. The second line contains $n$ numbers $a_i\:(1 \le a_i \le 10^9)$ of array. The third line contains the number of queries $m\:(1 \le m \le 10^5)$. Each of the next $m$ lines contain three numbers $q, l, r\:(1 \le l \le r \le n)$. If $q = 1$ you need to find the winner for a segment $[l; r]$, if $q = 2$ you need to replace the element at position $l$ to the number $r$
\OutputFile
For each query with number $1$ print in a separate line \textbf{"wins"}, if Victor wins, print \textbf{"loser"} if Victor lose and \textbf{"draw"} in a case of a draw.
Input example #1
5 2 4 6 10 8 6 1 1 5 1 2 3 2 5 15 2 3 10 1 3 5 1 1 1
Output example #1
wins wins wins draw