Download  Print this page

Displaying A Binary Integer; Pad (pad With Leading Spaces) - HP -28S Manual

Advanced scientific calculator.
Hide thumbs


Displaying a Binary Integer
This section contains three programs:
• PAD is a utility program that converts an object to a string for
right-justified display.
• PRESERVE is a utility program for use in programs that change the
calculator's status (angle mode, binary base, and so on).
• BDISP displays a binary integer in HEX, DEC, OCT, and BIN bases.
calls PAD to show the displayed numbers right-justified, and it
calls PRESERVE to preserve the binary base.
PAD (Pad With Leading Spaces)
Convert an object to a string and, if the string contains fewer than 23
characters, add spaces to the beginning.
When a short string is displayed by using DISP, it appears
its first character appears at the left end of the display. The
position of the last character is determined by the length of the string.
By adding spaces to the beginning of a short string, PAD moves the
position of the last character to the right. When the string is 23 char-
acters long, it appears
its last character appears at the
right end of the display.
PAD has no effect on strings that are longer than 22 characters.
1 : object
1 :
• WHILE ... REPEAT ... END (indefinite loop). The WHILE clause
contains a test that determines whether to execute the REPEAT
clause and test again (if true) or to skip the REPEAT clause and exit
(if false).
28: Programming Examples


Table of Contents

   Also See for HP HP-28S

   Related Manuals for HP HP-28S

Comments to this Manuals

Symbols: 0
Latest comments: