Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # Command: dc -fdc-p1-fast.dc <input
- # Precreating all the numerical constants and assigning them registers
- 0s0
- 1s1
- 2s2
- 3s3
- 4s4
- 5s5
- 64sa
- 32sb
- 2048sc
- 2000sd
- 24se
- _1sf
- # 24-bit XOR top two on stack (counter; 2 bits at a time)
- [
- l0d # (i=bit#) result
- [
- l3Rl4R # arg2 arg1 i result
- l4~ l3R l4~ # (B-low2) Brest (A-low2) Arest i result
- l3R
- dlfr^l3R*+l4dl3R+r% # (B^A low2) (B-rest) (A-rest) i result
- l4R d l2r^ l3R* # (bit<<i) i rest1 rest2 result
- l5R+ # (result+=bit) i rest1 rest2
- rl2+ d le>L # i+=2, loop until i == 24
- ] dsLx l3Rl4R++s. # 3 result junk2 junk1
- ] s^
- ?
- [
- #[num: ]np
- ld # i num
- [
- r # num i
- d la* l^x # num = (64*num) ^ num
- d lb/ l^x # num = (num/32) ^ num
- d lc* l^x # num = (2048*num) ^ num
- rl1- dl0<I
- ] dsIx +
- lp+sp
- ? zl0<M
- ] dsMx
- [Part 1: ]n lpp
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement