Module Main

    Sub Main()

        Dim s As String = String.Empty
        Dim cnt As Integer = 0

        '入力値取得
        s = Console.ReadLine

        For Each c In s
            If c = "1"c Then
                cnt += 1
            End If
        Next

        '処理結果出力
        Console.WriteLine(cnt.ToString)

    End Sub

End Module