Option Strict On
Module problemC

    Sub Main()
        Dim x As Integer = Integer.Parse(Console.ReadLine)
        Dim o As Integer = x Mod 10
        Dim t As Integer = (x Mod 100 - o) \ 10
        Dim p As Integer = 0

        Select Case o
            Case 1 To 5
                p = 1
            Case 2 To 9
                p = 2
        End Select

        If t > 0 Then
            p += t * 2
        End If

        Console.WriteLine(Convert.ToInt32(x >= p * 100))
    End Sub

End Module
