P5355 [Ynoi Easy Round 2017] Yuno's Cornfield
Background

Description
Yuno is taking a walk by her farmland. She suddenly finds that a row of corn in the field looks very ugly.
There are a total of $N$ corn plants in this row, and their heights are uneven.
Yuno thinks the cornfield is not beautiful, so she decides to make a data structure problem.
The problem is as follows:
You are given a sequence $a$ of length $n$, with $m$ operations. Each operation queries whether, in a given interval, you can pick two numbers whose difference is $x$, or queries whether, in a given interval, you can pick two numbers whose sum is $x$, or queries whether, in a given interval, you can pick two numbers whose product is $x$, or queries whether, in a given interval, you can pick two numbers whose quotient is $x$ (with no remainder). These four operations are numbered $1,2,3,4$, respectively.
The two chosen numbers may come from the same position.
Input Format
The first line contains two integers $n,m$.
The next line contains $n$ integers representing $a_i$.
The next $m$ lines each contain four integers $opt,l,r,x$.
$opt$ indicates which type of operation it is, $l,r$ specify the interval of the operation, and $x$ is the value $x$ for this operation.
Output Format
For each query, if it is possible, output `yuno`; otherwise output `yumi`.
Explanation/Hint
Idea: nzhtl1477, Solution: nzhtl1477, Code: nzhtl1477, Data: nzhtl1477&mrsrz.
For $100\%$ of the testdata, all input numbers are within $[0,10^5]$, and the elements in the sequence are within $[1,10^5]$.
Translated by ChatGPT 5