Data update

This commit is contained in:
Ingy döt Net 2026-04-30 12:34:36 -04:00
parent 4bb20c9b71
commit cbaf4c4b64
12390 changed files with 318560 additions and 27248 deletions

View file

@ -0,0 +1,21 @@
function is_squarefree(n) {
for (let i = 2; i <= Math.sqrt(n); i++) {
if (Number.isInteger(n / (i ** 2))) {
return false;
}
}
return true;
}
for (const n of [1, 10 ** 12 + 1]) {
console.log([...Array(145).keys()].map(x => x + n).filter(is_squarefree).join(" "));
}
let sqf = [];
for (let i = 1; i <= 1000000; i++) {
if (is_squarefree(i)) {
sqf.push(i);
} else if (Number.isInteger(Math.log10(i))) {
console.log(`There are ${sqf.length} square-free integers <=${i}`);
}
}