comp.lang.ada
 help / color / mirror / Atom feed
From: Tero Koskinen <tero.koskinen@iki.fi>
Subject: Re: Length-Limited Huffman Coding
Date: Thu, 11 Feb 2016 20:44:03 +0200
Date: 2016-02-11T20:44:03+02:00	[thread overview]
Message-ID: <n9ikpb$ma8$1@loke.gir.dk> (raw)
In-Reply-To: <2bdea64f-0f90-4f89-93d8-fafe2e93e3a9@googlegroups.com>

11.2.2016, 11.48, gautier_niouzes@hotmail.com wrote:
>>> builds on GNAT with the -gnat83 switch, so *perhaps* with all Ada
>>> compilers!...
>
> Randy:
>
>> Careful! You might talk me into digging out an old Janus/Ada 83 for MS-DOS.
>> :-)
>
> Teasing, isn't it ? Will you resist ?

I am not Randy, but I tested the code with Janus/Ada 3.1.2c
(on Windows 10) and it compiled and ran fine:

 > test_llh
Maximum Huffman code length (constraint):  4 bits
------------------------------------
     a freq = 10 length =  4
     b freq = 30 length =  2
     c freq = 12 length =  4
     d freq =  5 length =  4
     e freq = 17 length =  3
     f freq = 20 length =  3
     g freq = 17 length =  3
     h freq =  0 length =  0
     i freq = 20 length =  3
     j freq =  0 length =  0
     k freq = 15 length =  4
Maximum Huffman code length (constraint):  5 bits
------------------------------------
     a freq = 10 length =  5
     b freq = 30 length =  2
     c freq = 12 length =  4
     d freq =  5 length =  5
     e freq = 17 length =  3
     f freq = 20 length =  3
     g freq = 17 length =  3
     h freq =  0 length =  0
     i freq = 20 length =  3
     j freq =  0 length =  0
     k freq = 15 length =  3

 >

Although, Janus/Ada gave one warning:
In File C:\Work\gautier\llhc\LENGTH_LIMITED_HUFFMAN_CODE_LENGTHS.ADB at 
line 54
--------------
    53:    type Index_pair is array(Index_type'(0)..1) of Index_type;
    54:    lists: array(0..Index_type(max_bits-1)) of Index_pair;
-----------------------------------------------------^
*WARNING* This component has a non-simple type (6.5.2)
%%%%%%%


Yours,
  Tero


  reply	other threads:[~2016-02-11 18:44 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-02-06 20:57 Length-Limited Huffman Coding gautier_niouzes
2016-02-08 21:20 ` gautier_niouzes
2016-02-10 11:29   ` gautier_niouzes
2016-02-11  1:59     ` Randy Brukardt
2016-02-11  9:48       ` gautier_niouzes
2016-02-11 18:44         ` Tero Koskinen [this message]
2016-02-11 22:08           ` Randy Brukardt
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox