For problem statement at 1000-1999/1900-1999/1970-1979/1971/problemC.txt this is a correct solution, but verifier at 1000-1999/1900-1999/1970-1979/1971/verifierC.go ends with All tests passed can you fix the verifier? package main
import (
"bufio"
"fmt"
"os"
)
func between(x, a, b int) bool {
if a < b {
return a < x && x < b
}
return x > a || x < b
}
func main() {
in := bufio.NewReader(os.Stdin)
out := bufio.NewWriter(os.Stdout)
defer out.Flush()
var t int
fmt.Fscan(in, &t)
for i := 0; i < t; i++ {
var a, b, c, d int
fmt.Fscan(in, &a, &b, &c, &d)
if between(c, a, b) != between(d, a, b) {
fmt.Fprintln(out, "YES")
} else {
fmt.Fprintln(out, "NO")
}
}
}