const numbers = [];
let sum = 0,
lessThan50 = 0;
for (let i = 0; i < 37; i++) {
const number = Math.floor(Math.random() * 150);// random number 0..150
sum += number;
if (number < 50 && (number % 12) === 0) {
lessThan50++;
}
numbers.push(number);
}
const pre = document.createElement('pre');
pre.innerHTML += `Numbers: ${numbers.join(', ')}\n`;
pre.innerHTML += `Arithmetical mean: ${(sum / numbers.length).toFixed(3)}\n`;
pre.innerHTML += `Amount of numbers less than 50 and divisible by 12 without remainder: ${lessThan50}\n`;
//document.body.appendChild(pre);
console.log(pre.innerHTML);