From 47c92bf2770bc1cf7e0483715ac7bb498bbacb91 Mon Sep 17 00:00:00 2001 From: Cody Boone Ferguson <53008573+xexyl@users.noreply.github.com> Date: Sun, 22 Oct 2023 15:54:02 -0700 Subject: [PATCH] Further improve alt code of 2006/sloane Formatting looks more like the original. Also silence unused parameter that came about the fix for some versions of clang. --- 2006/sloane/Makefile | 2 +- 2006/sloane/sloane.alt.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/2006/sloane/Makefile b/2006/sloane/Makefile index 574c72680..325aba2a4 100644 --- a/2006/sloane/Makefile +++ b/2006/sloane/Makefile @@ -40,7 +40,7 @@ include ../../var.mk # CSILENCE= -Wno-error -Wno-implicit-function-declaration -Wno-implicit-int \ -Wno-pedantic -Wno-return-type -Wno-shift-op-parentheses -Wno-unsequenced \ - -Wno-deprecated-non-prototype -Wno-main + -Wno-deprecated-non-prototype -Wno-main -Wno-unused-parameter # Common C compiler warning flags # diff --git a/2006/sloane/sloane.alt.c b/2006/sloane/sloane.alt.c index 07968a165..b2fc5b618 100644 --- a/2006/sloane/sloane.alt.c +++ b/2006/sloane/sloane.alt.c @@ -27,6 +27,6 @@ A),m =cos(B);for(k =0;k< 1840;k++)y=-k g)*m-c* d*e-f*g-l*d*n);if(D>z[o] )z[o] =D,b[o] =" ..,,-++=#$@"[ N>0?N:0 ] ; } printf( - "\x1b[" "H" );usleep(S);for(k =1;1841 + "\x1b[" "H" );usleep(S);for(k=1;1841 >k;k++) putchar (k%80?b [k]:10) ; A += 0.053;B +=0.037 ; } }