process.stdin.resume();
process.stdin.setEncoding('utf8');
var lines = [];
var n;
var x = [];
var min;
var k = 1;
var y = [];
var reader = require('readline').createInterface({
    input: process.stdin,
    output: process.stdout
});
reader.on('line', (line) => {
    lines.push(line);
});
reader.on('close', () => {
    n = parseInt(lines[0]);
    x = lines[1].split(' ');
      
        for (var i = 0; i < n; i++) {
             y = x.splice(0,x.length-i+1);
            while (parseInt(y[y.length - i]) != Math.max(y)) {
                y[y.length - i] = parseInt(y[y.length - i]) + 1;
                x[x.length - i] = parseInt(x[x.length - i]) + 1;
                 
            }
        }
    console.log(x.join(' '));
});