function Main(input) {
	var n  = input.match(/10+/)
	if(n!==null) console.log(10);
	else console.log(input[0]-0+(input.slice(1,input.length)-0));
}Main(require("fs").readFileSync("/dev/stdin", "utf8").trim());