function Main(input) {
	input = input.split('\n');

	var reg = new RegExp(`[a-z]{0,${input[1]}}`, 'g');
	console.log(input[0].match(reg).map(str => str[0]).join(''));
}

Main(require("fs").readFileSync("/dev/stdin", "utf8"));
