๐Ÿš€ go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.lang.c
Article #1204

Re: BizFuss (was Re: Taming The Switch-Statement)

#1204
From: Rosario19
Date: Sat, 31 Oct 2026 13:30
72 lines
3775 bytes
On Sat, 31 Oct 2026 12:21:13 +0000, bartc <bc@freeuk.com> wrote:

>On 31/10/2026 10:39, Rosario19 wrote:
>> On Fri, 30 Oct 2026 11:47:59 +0000, bartc  wrote:
>> 
>>> That output becomes:
>>>
>>>    167 is not divisible by any of (2,3,5,7)
>>>    168 is divisible by 2
>>>    168 is divisible by 3
>>>    168 is divisible by 7
>>>    169 is not divisible by any of (2,3,5,7)
>>>
>>> Sizes (with hard tabs and no comments):
>>>
>>>   Your Python:  340 characters
>>>   Mine:         222    (as above; scripting)
>>>   C:            393    (not shown; not elegant)
>>>   Mine:         314    (not shown; systems lang)
>> 
>> The APL one is 80 characters
>
>That's not quite right:
>
>* You're using 2,3,7 not 2,3,5,7, which would add 2 characters
>
>* You're doing 20 iterations not 200 (adds 1 more character!)

code I posted is 2 input one left (the list 2 3 7) and one in the
right (the number 20) and the APL function in the middle. 

80 charaters refer only for APL function. 
So the number of characters of the function + the input is more than
80. It is possible change the input [input left the list 2 3 5 7,
input right the integer 200] for have this

     2 3 5 7{a???{0=?k?a/?0=a|?:???,' is not divisible by ',a????,' is
divisible by ',k}ยจ??}200
1  is not divisible by  2 3 5 7
2  is divisible by  2
3  is divisible by  3
4  is divisible by  2
5  is divisible by  5
6  is divisible by  2 3
7  is divisible by  7
8  is divisible by  2
9  is divisible by  3
10  is divisible by  2 5
11  is not divisible by  2 3 5 7
12  is divisible by  2 3
13  is not divisible by  2 3 5 7
14  is divisible by  2 7
15  is divisible by  3 5
16  is divisible by  2
17  is not divisible by  2 3 5 7
18  is divisible by  2 3
19  is not divisible by  2 3 5 7
20  is divisible by  2 5
21  is divisible by  3 7
22  is divisible by  2
23  is not divisible by  2 3 5 7
24  is divisible by  2 3
25  is divisible by  5
...............
196  is divisible by  2 7
197  is not divisible by  2 3 5 7
198  is divisible by  2 3
199  is not divisible by  2 3 5 7
200  is divisible by  2 5


Technical Details
Message-ID: <jjqbeldmt29qt3jjrrlb7j9nuubmvleuvp@4ax.com>
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!eternal-september.org!feeder.eternal-september.org!nntp.eternal-september.org!.POSTED!not-for-mail
References: <11bnfpm$i84l$1@dont-email.me> <11bng23$iblc$1@dont-email.me> <11bngj1$ifj5$1@dont-email.me> <11bnnbg$l7i1$1@dont-email.me> <11bntk0$nsbo$1@dont-email.me> <11bnvbq$olbj$1@dont-email.me> <11bo02r$otr5$1@dont-email.me> <11bo0ul$pbso$1@dont-email.me> <11bo1bc$phlr$1@dont-email.me> <tft5elp1q2ns7rhfp3rod862ks5ip3p0ms@4ax.com> <11c1kee$2lqi$2@dont-email.me> <11c205f$73k2$1@dont-email.me> <t8hbelloceeupncsjjl41ah7jd4vv2gms3@4ax.com> <11c4mfp$13b6a$1@dont-email.me>

Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!eternal-september.org!feeder.eternal-september.org!nntp.eternal-september.org!.POSTED!not-for-mail
From: Rosario19 <Ros@invalid.invalid>
Newsgroups: comp.lang.c
Subject: Re: BizFuss (was Re: Taming The Switch-Statement)
Date: Sat, 31 Oct 2026 14:30:54 +0100
Organization: A noiseless patient Spider
Lines: 72
Message-ID: <jjqbeldmt29qt3jjrrlb7j9nuubmvleuvp@4ax.com>
References: <11bnfpm$i84l$1@dont-email.me> <11bng23$iblc$1@dont-email.me> <11bngj1$ifj5$1@dont-email.me> <11bnnbg$l7i1$1@dont-email.me> <11bntk0$nsbo$1@dont-email.me> <11bnvbq$olbj$1@dont-email.me> <11bo02r$otr5$1@dont-email.me> <11bo0ul$pbso$1@dont-email.me> <11bo1bc$phlr$1@dont-email.me> <tft5elp1q2ns7rhfp3rod862ks5ip3p0ms@4ax.com> <11c1kee$2lqi$2@dont-email.me> <11c205f$73k2$1@dont-email.me> <t8hbelloceeupncsjjl41ah7jd4vv2gms3@4ax.com> <11c4mfp$13b6a$1@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: 8bit
Injection-Date: Sat, 31 Oct 2026 13:22:58 +0000 (UTC)
Injection-Info: dont-email.me;
	logging-data="1201144"; mail-complaints-to="abuse@eternal-september.org";	posting-account="U2FsdGVkX1/Comxpy72x7H0MVxO0zoHodzu1ntOqPeg="; posting-host="16b6d0dc3bfca910e87f2c3e3067af6e"
Cancel-Lock: sha1:y2DTlItxQyhx4xzeNfj4DF8lh00= sha256:IFZLVqBPFZzTmzuaavAFKccH647kp0IGaTxBqLPFcA0=
	sha1:wuU4nHEd4Sp4/SsopL/qR4FOoOw= sha256:EhSY6LSUP3l9ZiiSpVjS6QcxMOtB4d4bZERGaUjOTOs=
X-Newsreader: Forte Free Agent 1.93/32.576 English (American)