Make circle more circular

master
Chloe Fontenot 🏳️‍⚧️ 2023-04-08 19:00:22 +07:00
parent e62a10fa07
commit 0e1731fbc4
1 changed files with 2 additions and 2 deletions

@ -168,14 +168,14 @@ function design4(input) {
space += " "; space += " ";
} }
// for horizontal movement // for horizontal movement
for (let i = 0; i <= 1.5 * radius; i++) { for (let i = 0; i <= 2 * radius; i++) {
if (i != mid) { if (i != mid) {
// for vertical movement // for vertical movement
for (let j = 0; j <= 2 * radius; j++) { for (let j = 0; j <= 2 * radius; j++) {
dist = Math.sqrt( dist = Math.sqrt(
(i - radius) * (i - radius) + (i - radius) * (i - radius) +
(j - radius) * (j - radius) (j - radius / 2) * (j - radius / 2)
); );
// dist should be in the range (radius - 0.5) // dist should be in the range (radius - 0.5)