def main(): z = input() print(sum(map(int, z)) + 10*z.count('0')) if __name__ == '__main__': main()