"use strict";
    
const main = arg => {
    arg = arg.trim().split("\n");
    const N = parseInt(arg[0].split(" ")[0]);
    const bonus = Math.floor(N / 15) * 200;
    
    const x = (N * 800);
    
    console.log(x - bonus);
}
main(require('fs').readFileSync('/dev/stdin', 'utf8'));