let K = Int(readLine()!)!
let input = readLine()!.split(separator: " ").map { Int($0)! }
let A = input[0]
let B = input[1]

if A % K == 0 {
    print("OK")
} else {
    print(A / K != B / K ? "OK" : "NG")
}
