Data update
This commit is contained in:
parent
29a5eea0d4
commit
5c1bb7bfa9
2011 changed files with 35081 additions and 3229 deletions
|
|
@ -2,31 +2,23 @@
|
|||
' compile with: fbc -s console
|
||||
|
||||
Function gray2bin(g As UInteger) As UInteger
|
||||
|
||||
Dim As UInteger b = g
|
||||
|
||||
While g
|
||||
g Shr= 1
|
||||
b Xor= g
|
||||
Wend
|
||||
|
||||
Return b
|
||||
|
||||
End Function
|
||||
|
||||
Function bin2gray(b As UInteger) As UInteger
|
||||
|
||||
Return b Xor (b Shr 1)
|
||||
|
||||
End Function
|
||||
|
||||
' ------=< MAIN >=------
|
||||
|
||||
Dim As UInteger i
|
||||
|
||||
Print " i binary gray gra2bin"
|
||||
Print String(32,"=")
|
||||
|
||||
For i = 0 To 31
|
||||
Print Using "## --> "; i;
|
||||
print Bin(i,5); " --> ";
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue