Add missing alt code to 1990/baruch

I did this a while back but somehow forgot to do a git add baruch.alt.c
so the alt code was only referenced in the README.md and Makefile. That
has now been corrected.
This commit is contained in:
Cody Boone Ferguson committed 2023-04-17 10:07:31 -07:00
1 parent 9f34987616
commit 28554b7791
2 files changed
+7

No files matched your search

+1
View File
@@ -1 +1,2 @@
baruch
baruch.alt
+6
View File
@@ -0,0 +1,6 @@
int v,i,j,k,l,s,a[99];
int main(void)
{
for(scanf("%d",&s);*a-s;v=a[j*=v]-a[i],k=i<s,j+=(v=j<s&&(!k&&!!printf(2+"\n\n%c"-(!l<<!j)," #Q"[l^v?(l^j)&1:2])&&++l||a[i]<s&&v&&v-i+j&&v+i-j))&&!(l%=s),v||(i==j?a[i+=k]=0:++a[i])>=s*k&&++a[--i])
;puts("");
}