home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Power-Programmierung
/
CD1.mdf
/
forth
/
compiler
/
fpc
/
source
/
p3_6bs.seq
< prev
next >
Wrap
Text File
|
1990-04-06
|
748b
|
26 lines
\ Balraj Sidhu Set: 14D4
\ Comp 462 - Forth
\ Date: April 6, 1990
\ Problem 3.6
\ Illustration of Number Bases and formatted display operators
: ntable ( dn -- )
cr ." Unsigned" ." Signed" ." Unsigned"
." Signed" ." Unsigned" ." Signed"
cr ." Decimal" ." Decimal" ." Octal "
." Octal " ." Hex " ." Hex "
20 0 do
cr
decimal dup 13 u.r
dup 13 .r
octal dup 13 u.r
dup 13 .r
hex dup 13 u.r
dup 13 .r
1 +
loop
drop decimal ;