HP Forums

Full Version: GETBITS syntax
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
I wonder why GETBITS(#255d) it's ok but GETBITS(255) not (error: invalid input).
It could be interpreted "as default" as decimal...
Or not?

Salvo
Hi!, salvomic:

Syntax: GETBITS(#integer) Returns the number, of bits, used by integer, expressed, in the default base.
Example: GETBITS(#22122) returns #20h or 32.

Kind Regards.
informach.
thank you, I know it...
I mean: "why is the # mandatory?"
Hi Salvo,

The syntax for this requires the integer base in order to determine the encoding. It uses the default base if not specified, but in any event, that means you would need to use the integer syntax (#number, o, d, h).

-Dale-
(05-12-2016 09:49 PM)DrD Wrote: [ -> ]Hi Salvo,

The syntax for this requires the integer base in order to determine the encoding. It uses the default base if not specified, but in any event, that means you would need to use the integer syntax (#number, o, d, h).

-Dale-

thank you Dale,
now it is very clear for me.

Salvo
Reference URL's