function Main(input) {
    var array = input.replace(/\r?\n+$/, '').split(/\s+/).map(Number);

    if ( array[0] == array[1] == array[2] ) {
        console.log("1");
    } else if ( array[0] == array[1] || array[1] == array[2] ) {
        console.log("2");
    } else {
        console.log("3");
    }
}

var character = "";
process.stdin.on('data', function(char){ character += char });
process.stdin.on('end', function(){ Main(character); });
process.on('SIGINT', function() { Main(character); process.exit(0); });