[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: bc and dc.
From: |
Alejandro Colomar |
Subject: |
Re: bc and dc. |
Date: |
Fri, 28 Apr 2023 15:46:28 +0200 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.10.0 |
Hi Raplh,
On 4/28/23 15:43, Ralph Corderoy wrote:
> Hi Alejandro,
>
>> I could only see this:
>>
>> $ echo 'l(1114112) / l(2)' | bc -lc
>> @iK1114112:C2,0:K2:C2,0:/W@r
>> @i
>
> That's GNU bc. Its -c dumps its internal byte code rather than dc code
> because it nevers runs dc.
>
>> $ echo 'l(1114112) / l(2)' | /usr/lib/plan9/bin/bc -c
>> 1114112 l<12>x 2 l<12>x/ps.
>> q
>
> That's correct output. The <12> is ASCII FF and is the name of the l()
> function as defined by the dc code in bc's -l maths library.
>
>> $ echo 'l(1114112) / l(2)' | /usr/lib/plan9/bin/bc -lc
>> c[cannot open input file:1, ]pc
>> 1114112 l<12>x 2 l<12>x/ps.
>> q
>
> There's your problem. When your plan9/bin/bc is given -l, it produces
> dc to print ‘cannot open input file:1, ’. Looks like the installation
> is incomplete or the file is present but in the wrong place.
>
> At a guess, have you a /usr/lib/plan9/lib/bclib?
It seems Debian's plan9 port is incomplete in that regard:
$ apt-file find /usr/lib/plan9/lib/bclib
$ apt-file find bclib
$
$ apt-file find /usr/lib/plan9/bin/bc
9base: /usr/lib/plan9/bin/bc
:(
Cheers,
Alex
- Re: neatroff for Russian. (Was: Questions concerning hyphenation patterns for non-Latin languages, e.g. Russian), (continued)
- Re: neatroff for Russian. (Was: Questions concerning hyphenation patterns for non-Latin languages, e.g. Russian), Oliver Corff, 2023/04/26
- Re: neatroff for Russian. (Was: Questions concerning hyphenation patterns for non-Latin languages, e.g. Russian), Robin Haberkorn, 2023/04/26
- Re: neatroff for Russian. (Was: Questions concerning hyphenation patterns for non-Latin languages, e.g. Russian), G. Branden Robinson, 2023/04/26
- Re: neatroff for Russian. (Was: Questions concerning hyphenation patterns for non-Latin languages, e.g. Russian), Oliver Corff, 2023/04/26
- Re: neatroff for Russian. (Was: Questions concerning hyphenation patterns for non-Latin languages, e.g. Russian), G. Branden Robinson, 2023/04/26
- Re: neatroff for Russian. (Was: Questions concerning hyphenation patterns for non-Latin languages, e.g. Russian), Alejandro Colomar, 2023/04/27
- precision of bc/dc and properties of logarithms (was: neatroff for Russian), G. Branden Robinson, 2023/04/28
- Re: bc and dc. (Was: neatroff for Russian.), Ralph Corderoy, 2023/04/28
- Re: bc and dc. (Was: neatroff for Russian.), Alejandro Colomar, 2023/04/28
- Re: bc and dc., Ralph Corderoy, 2023/04/28
- Re: bc and dc.,
Alejandro Colomar <=
- Re: neatroff for Russian. (Was: Questions concerning hyphenation patterns for non-Latin languages, e.g. Russian), Oliver Corff, 2023/04/29
- Re: neatroff for Russian. (Was: Questions concerning hyphenation patterns for non-Latin languages, e.g. Russian), Dave Kemper, 2023/04/29
- Re: neatroff for Russian. (Was: Questions concerning hyphenation patterns for non-Latin languages, e.g. Russian), G. Branden Robinson, 2023/04/30
- Re: Perl and linguistics. (Was: neatroff for Russian.), Ralph Corderoy, 2023/04/30
- Re: neatroff for Russian. (Was: Questions concerning hyphenation patterns for non-Latin languages, e.g. Russian), Dave Kemper, 2023/04/29
- Re: neatroff for Russian., Ralph Corderoy, 2023/04/27
- Re: Questions concerning hyphenation patterns for non-Latin languages, e.g. Russian, Robin Haberkorn, 2023/04/26