Imports System

Module practiceA
    Sub Main()
        Call test1()


    End Sub

    Sub test1()
        Dim K, i, A, B As Integer
        Dim arr(2) As String

        K = Console.ReadLine()
        arr = Split(Console.ReadLine())
        A = arr(0)
        B = arr(1)

        If A <= B Then

            While K * i <= 1000

                If K * i >= A And K * i <= B Then
                    Console.Write("OK")
                    Exit Sub
                Else
                    i = i + 1
                End If

            End While

        End If

        Console.Write("NG")

    End Sub

    Sub test2()
        Dim A, B, C, D, HP_A, HP_B As Integer
        Dim arr(4) As String
        arr = Split(Console.ReadLine())
        A = arr(0)
        B = arr(1)
        C = arr(2)
        D = arr(3)

        HP_B = C - B


        If HP_B <= 0 Then
            Console.Write("Yes")
            Exit Sub
        End If

        HP_A = A - D

        If HP_A <= 0 Then
            Console.Write("No")
            Exit Sub
        End If

        Do While True

            HP_B = HP_B - B

            If HP_B <= 0 Then
                Console.Write("Yes")
                Exit Do
            End If

            HP_A = HP_A - D

            If HP_A <= 0 Then
                Console.Write("No")
                Exit Do
            End If

        Loop

    End Sub

    Sub test3()
        Dim N, i, count As Integer

        count = 1

        N = Console.ReadLine()

        Dim stringlist(N - 1) As String

        For i = 0 To N - 1
            stringlist(i) = Console.ReadLine()
        Next i

        Dim uniqueFoods() As String = stringlist.Distinct.ToArray

        count = uniqueFoods.Length

        Console.WriteLine(count)

    End Sub


End Module