const input = require("fs").readFileSync(0,"utf8").toString().trim().split('\n');
const n = Number(input[0]);
const size = input[1].split(' ').map(Number);
const [t, p] = input[2].split(' ').map(Number);

const total_t = size.reduce((acc,val) => acc + Math.ceil(val/t), 0);
console.log(total_t);

const pencil_set = Math.floor(n/p);
const pencil = n%p;
console.log(pencil_set,pencil);