- 2048 for the TI84
- 19 Apr 2014 05:50:50 pm
- Last edited by tfromme on 19 Apr 2014 07:01:32 pm; edited 2 times in total
I am programming a 2048 game, and have a decent one that works right now, however it runs dreadfully slow. I wonder if anyone can help optimize it so it runs faster?
I expected to use output and random more, that is why they are separate, I will combine in future though. Output just outputs the numbers on the screen, and random picks a random unoccupied spot to put another 2.
EDIT: I do not know the source code for prgmASM, since I got it off the internet, but all it does is switch the prgm and home commands, allowing me to use Archive and UnArchive within the program. I run this from mirageOS so that it doesn't take up RAM, and have the other programs(except ASM which is really small) archived as well.
EDIT2: Pic3 is the grid which I drew, and GDB0 is the standard graph screen, in case of functions interfering.
Code:
prgmOUTPUT code:
Code:
prgmRANDOM code:
Code:
I expected to use output and random more, that is why they are separate, I will combine in future though. Output just outputs the numbers on the screen, and random picks a random unoccupied spot to put another 2.
EDIT: I do not know the source code for prgmASM, since I got it off the internet, but all it does is switch the prgm and home commands, allowing me to use Archive and UnArchive within the program. I run this from mirageOS so that it doesn't take up RAM, and have the other programs(except ASM which is really small) archived as well.
EDIT2: Pic3 is the grid which I drew, and GDB0 is the standard graph screen, in case of functions interfering.
Code:
:ClrDraw
Asm(prgmASM)
UnArchive GDB0
RecallGDB 0
Archive GDB0
Asm(prgmASM)
AxesOff
RecallPic 3
0->|LZ048(1)
0->|LZ048(2)
0->|LZ048(3)
0->|LZ048(4)
0->|LZ048(5)
0->|LZ048(6)
0->|LZ048(7)
0->|LZ048(8)
0->|LZ048(9)
0->|LZ048(10)
0->|LZ048(11)
0->|LZ048(12)
0->|LZ048(13)
0->|LZ048(14)
0->|LZ048(15)
0->|LZ048(16)
2->|LZ048(randInt(1,16))
0->Q
While Q!=3.232
Asm(prgmASM)
UnArchive prgmRANDOM
UnArchive prgmOUTPUT
Asm(prgmASM)
prgmRANDOM
prgmOUTPUT
Asm(prgmASM)
Archive prgmRANDOM
Archive prgmOUTPUT
Asm(prgmASM)
0->G
While G!=24 and G!=25 and G!=26 and G!=34
getKey->G
End
If G=24
Then
If |LZ048(1)!=0 or |LZ048(2)!=0 or |LZ048(3)!=0 or |LZ048(4)!=0
Then
While |LZ048(1)=0
|LZ048(2)->|LZ048(1)
|LZ048(3)->|LZ048(2)
|LZ048(4)->|LZ048(3)
0->|LZ048(4)
End
If |LZ048(3)!=0 or |LZ048(4)!=0
Then
While |LZ048(2)=0
|LZ048(3)->|LZ048(2)
|LZ048(4)->|LZ048(3)
0->|LZ048(4)
End
End
If |LZ048(4)!=0
Then
While |LZ048(3)=0
|LZ048(4)->|LZ048(3)
0->|LZ048(4)
End
End
If |LZ048(1)=|LZ048(2) and |LZ048(1)!=0
Then
2(|LZ048(1))->|LZ048(1)
|LZ048(3)->|LZ048(2)
|LZ048(4)->|LZ048(3)
0->|LZ048(4)
End
If |LZ048(2)=|LZ048(3) and |LZ048(2)!=0
Then
2(|LZ048(2))->|LZ048(2)
|LZ048(4)->|LZ048(3)
0->|LZ048(4)
End
If |LZ048(3)=|LZ048(4) and |LZ048(3)!=0
Then
2(|LZ048(3))->|LZ048(3)
0->|LZ048(4)
End
End
If |LZ048(5)!=0 or |LZ048(6)!=0 or |LZ048(7)!=0 or |LZ048(8)!=0
Then
While |LZ048(5)=0
|LZ048(6)->|LZ048(5)
|LZ048(7)->|LZ048(6)
|LZ048(8)->|LZ048(7)
0->|LZ048(8)
End
If |LZ048(7)!=0 or |LZ048(8)!=0
Then
While |LZ048(6)=0
|LZ048(7)->|LZ048(6)
|LZ048(8)->|LZ048(7)
0->|LZ048(8)
End
End
If |LZ048(8)!=0
Then
While |LZ048(7)=0
|LZ048(8)->|LZ048(7)
0->|LZ048(8)
End
End
If |LZ048(5)=|LZ048(6) and |LZ048(5)!=0
Then
2(|LZ048(5))->|LZ048(5)
|LZ048(7)->|LZ048(6)
|LZ048(8)->|LZ048(7)
0->|LZ048(8)
End
If |LZ048(6)=|LZ048(7) and |LZ048(6)!=0
Then
2(|LZ048(6))->|LZ048(6)
|LZ048(8)->|LZ048(7)
0->|LZ048(8)
End
If |LZ048(7)=|LZ048(8) and |LZ048(7)!=0
Then
2(|LZ048(7))->|LZ048(7)
0->|LZ048(8)
End
End
If |LZ048(9)!=0 or |LZ048(10)!=0 or |LZ048(11)!=0 or |LZ048(12)!=0
Then
While |LZ048(9)=0
|LZ048(10)->|LZ048(9)
|LZ048(11)->|LZ048(10)
|LZ048(12)->|LZ048(11)
0->|LZ048(12)
End
If |LZ048(11)!=0 or |LZ048(12)!=0
Then
While |LZ048(10)=0
|LZ048(11)->|LZ048(10)
|LZ048(12)->|LZ048(11)
0->|LZ048(12)
End
End
If |LZ048(12)!=0
Then
While |LZ048(11)=0
|LZ048(12)->|LZ048(11)
0->|LZ048(12)
End
End
If |LZ048(9)=|LZ048(10) and |LZ048(9)!=0
Then
2(|LZ048(9))->|LZ048(9)
|LZ048(11)->|LZ048(10)
|LZ048(12)->|LZ048(11)
0->|LZ048(12)
End
If |LZ048(10)=|LZ048(11) and |LZ048(10)!=0
Then
2(|LZ048(10))->|LZ048(10)
|LZ048(12)->|LZ048(11)
0->|LZ048(12)
End
If |LZ048(11)=|LZ048(12) and |LZ048(11)!=0
Then
2(|LZ048(11))->|LZ048(11)
0->|LZ048(12)
End
End
If |LZ048(13)!=0 or |LZ048(14)!=0 or |LZ048(15)!=0 or |LZ048(16)!=0
Then
While |LZ048(13)=0
|LZ048(14)->|LZ048(13)
|LZ048(15)->|LZ048(14)
|LZ048(16)->|LZ048(15)
0->|LZ048(16)
End
If |LZ048(15)!=0 or |LZ048(16)!=0
Then
While |LZ048(14)=0
|LZ048(15)->|LZ048(14)
|LZ048(16)->|LZ048(15)
0->|LZ048(16)
End
End
If |LZ048(16)!=0
Then
While |LZ048(15)=0
|LZ048(16)->|LZ048(15)
0->|LZ048(16)
End
End
If |LZ048(13)=|LZ048(14) and |LZ048(13)!=0
Then
2(|LZ048(13))->|LZ048(13)
|LZ048(15)->|LZ048(14)
|LZ048(16)->|LZ048(15)
0->|LZ048(16)
End
If |LZ048(14)=|LZ048(15) and |LZ048(14)!=0
Then
2(|LZ048(14))->|LZ048(14)
|LZ048(16)->|LZ048(15)
0->|LZ048(16)
End
If |LZ048(15)=|LZ048(16) and |LZ048(15)!=0
Then
2(|LZ048(15))->|LZ048(15)
0->|LZ048(16)
End
End
End
If G=25
Then
If |LZ048(1)!=0 or |LZ048(5)!=0 or |LZ048(9)!=0 or |LZ048(13)!=0
Then
While |LZ048(1)=0
|LZ048(5)->|LZ048(1)
|LZ048(9)->|LZ048(5)
|LZ048(13)->|LZ048(9)
0->|LZ048(13)
End
If |LZ048(9)!=0 or |LZ048(13)!=0
Then
While |LZ048(5)=0
|LZ048(9)->|LZ048(5)
|LZ048(13)->|LZ048(9)
0->|LZ048(13)
End
End
If |LZ048(13)!=0
Then
While |LZ048(9)=0
|LZ048(13)->|LZ048(9)
0->|LZ048(13)
End
End
If |LZ048(1)=|LZ048(5) and |LZ048(1)!=0
Then
2(|LZ048(1))->|LZ048(1)
|LZ048(9)->|LZ048(5)
|LZ048(13)->|LZ048(9)
0->|LZ048(13)
End
If |LZ048(5)=|LZ048(9) and |LZ048(5)!=0
Then
2(|LZ048(5))->|LZ048(5)
|LZ048(13)->|LZ048(9)
0->|LZ048(13)
End
If |LZ048(9)=|LZ048(13) and |LZ048(9)!=0
Then
2(|LZ048(9))->|LZ048(9)
0->|LZ048(13)
End
End
If |LZ048(2)!=0 or |LZ048(6)!=0 or |LZ048(10)!=0 or |LZ048(14)!=0
Then
While |LZ048(2)=0
|LZ048(6)->|LZ048(2)
|LZ048(10)->|LZ048(6)
|LZ048(14)->|LZ048(10)
0->|LZ048(14)
End
If |LZ048(10)!=0 or |LZ048(14)!=0
Then
While |LZ048(6)=0
|LZ048(10)->|LZ048(6)
|LZ048(14)->|LZ048(10)
0->|LZ048(14)
End
End
If |LZ048(14)!=0
Then
While |LZ048(10)=0
|LZ048(14)->|LZ048(10)
0->|LZ048(14)
End
End
If |LZ048(2)=|LZ048(6) and |LZ048(2)!=0
Then
2(|LZ048(2))->|LZ048(2)
|LZ048(10)->|LZ048(6)
|LZ048(14)->|LZ048(10)
0->|LZ048(14)
End
If |LZ048(6)=|LZ048(10) and |LZ048(6)!=0
Then
2(|LZ048(6))->|LZ048(6)
|LZ048(14)->|LZ048(10)
0->|LZ048(14)
End
If |LZ048(10)=|LZ048(14) and |LZ048(10)!=0
Then
2(|LZ048(10))->|LZ048(10)
0->|LZ048(14)
End
End
If |LZ048(3)!=0 or |LZ048(7)!=0 or |LZ048(11)!=0 or |LZ048(15)!=0
Then
While |LZ048(3)=0
|LZ048(7)->|LZ048(3)
|LZ048(11)->|LZ048(7)
|LZ048(15)->|LZ048(11)
0->|LZ048(15)
End
If |LZ048(11)!=0 or |LZ048(15)!=0
Then
While |LZ048(7)=0
|LZ048(11)->|LZ048(7)
|LZ048(15)->|LZ048(11)
0->|LZ048(15)
End
End
If |LZ048(15)!=0
Then
While |LZ048(11)=0
|LZ048(15)->|LZ048(11)
0->|LZ048(15)
End
End
If |LZ048(3)=|LZ048(7) and |LZ048(3)!=0
Then
2(|LZ048(3))->|LZ048(3)
|LZ048(11)->|LZ048(7)
|LZ048(15)->|LZ048(11)
0->|LZ048(15)
End
If |LZ048(7)=|LZ048(11) and |LZ048(7)!=0
Then
2(|LZ048(7))->|LZ048(7)
|LZ048(15)->|LZ048(11)
0->|LZ048(15)
End
If |LZ048(11)=|LZ048(15) and |LZ048(11)!=0
Then
2(|LZ048(11))->|LZ048(11)
0->|LZ048(15)
End
End
If |LZ048(4)!=0 or |LZ048(8)!=0 or |LZ048(12)!=0 or |LZ048(16)!=0
Then
While |LZ048(4)=0
|LZ048(8)->|LZ048(4)
|LZ048(12)->|LZ048(8)
|LZ048(16)->|LZ048(12)
0->|LZ048(16)
End
If |LZ048(12)!=0 or |LZ048(16)!=0
Then
While |LZ048(8)=0
|LZ048(12)->|LZ048(8)
|LZ048(16)->|LZ048(12)
0->|LZ048(16)
End
End
If |LZ048(16)!=0
Then
While |LZ048(12)=0
|LZ048(16)->|LZ048(12)
0->|LZ048(16)
End
End
If |LZ048(4)=|LZ048(8) and |LZ048(4)!=0
Then
2(|LZ048(4))->|LZ048(4)
|LZ048(12)->|LZ048(8)
|LZ048(16)->|LZ048(12)
0->|LZ048(16)
End
If |LZ048(8)=|LZ048(12) and |LZ048(8)!=0
Then
2(|LZ048(8))->|LZ048(8)
|LZ048(16)->|LZ048(12)
0->|LZ048(16)
End
If |LZ048(12)=|LZ048(16) and |LZ048(12)!=0
Then
2(|LZ048(12))->|LZ048(12)
0->|LZ048(16)
End
End
End
If G=26
Then
If |LZ048(4)!=0 or |LZ048(3)!=0 or |LZ048(2)!=0 or |LZ048(1)!=0
Then
While |LZ048(4)=0
|LZ048(3)->|LZ048(4)
|LZ048(2)->|LZ048(3)
|LZ048(1)->|LZ048(2)
0->|LZ048(1)
End
If |LZ048(2)!=0 or |LZ048(1)!=0
Then
While |LZ048(3)=0
|LZ048(2)->|LZ048(3)
|LZ048(1)->|LZ048(2)
0->|LZ048(1)
End
End
If |LZ048(1)!=0
Then
While |LZ048(2)=0
|LZ048(1)->|LZ048(2)
0->|LZ048(1)
End
End
If |LZ048(4)=|LZ048(3) and |LZ048(4)!=0
Then
2(|LZ048(4))->|LZ048(4)
|LZ048(2)->|LZ048(3)
|LZ048(1)->|LZ048(2)
0->|LZ048(1)
End
If |LZ048(3)=|LZ048(2) and |LZ048(3)!=0
Then
2(|LZ048(3))->|LZ048(3)
|LZ048(1)->|LZ048(2)
0->|LZ048(1)
End
If |LZ048(2)=|LZ048(1) and |LZ048(2)!=0
Then
2(|LZ048(2))->|LZ048(2)
0->|LZ048(1)
End
End
If |LZ048(8)!=0 or |LZ048(7)!=0 or |LZ048(6)!=0 or |LZ048(5)!=0
Then
While |LZ048(8)=0
|LZ048(7)->|LZ048(8)
|LZ048(6)->|LZ048(7)
|LZ048(5)->|LZ048(6)
0->|LZ048(5)
End
If |LZ048(6)!=0 or |LZ048(5)!=0
Then
While |LZ048(7)=0
|LZ048(6)->|LZ048(7)
|LZ048(5)->|LZ048(6)
0->|LZ048(5)
End
End
If |LZ048(5)!=0
Then
While |LZ048(6)=0
|LZ048(5)->|LZ048(6)
0->|LZ048(5)
End
End
If |LZ048(8)=|LZ048(7) and |LZ048(8)!=0
Then
2(|LZ048(8))->|LZ048(8)
|LZ048(6)->|LZ048(7)
|LZ048(5)->|LZ048(6)
0->|LZ048(5)
End
If |LZ048(7)=|LZ048(6) and |LZ048(7)!=0
Then
2(|LZ048(7))->|LZ048(7)
|LZ048(5)->|LZ048(6)
0->|LZ048(5)
End
If |LZ048(6)=|LZ048(5) and |LZ048(6)!=0
Then
2(|LZ048(6))->|LZ048(6)
0->|LZ048(5)
End
End
If |LZ048(12)!=0 or |LZ048(11)!=0 or |LZ048(10)!=0 or |LZ048(9)!=0
Then
While |LZ048(12)=0
|LZ048(11)->|LZ048(12)
|LZ048(10)->|LZ048(11)
|LZ048(9)->|LZ048(10)
0->|LZ048(9)
End
If |LZ048(10)!=0 or |LZ048(9)!=0
Then
While |LZ048(11)=0
|LZ048(10)->|LZ048(11)
|LZ048(9)->|LZ048(10)
0->|LZ048(9)
End
End
If |LZ048(9)!=0
Then
While |LZ048(10)=0
|LZ048(9)->|LZ048(10)
0->|LZ048(9)
End
End
If |LZ048(12)=|LZ048(11) and |LZ048(12)!=0
Then
2(|LZ048(12))->|LZ048(12)
|LZ048(10)->|LZ048(11)
|LZ048(9)->|LZ048(10)
0->|LZ048(9)
End
If |LZ048(11)=|LZ048(10) and |LZ048(11)!=0
Then
2(|LZ048(11))->|LZ048(11)
|LZ048(9)->|LZ048(10)
0->|LZ048(9)
End
If |LZ048(10)=|LZ048(9) and |LZ048(10)!=0
Then
2(|LZ048(10))->|LZ048(10)
0->|LZ048(9)
End
End
If |LZ048(16)!=0 or |LZ048(15)!=0 or |LZ048(14)!=0 or |LZ048(13)!=0
Then
While |LZ048(16)=0
|LZ048(15)->|LZ048(16)
|LZ048(14)->|LZ048(15)
|LZ048(13)->|LZ048(14)
0->|LZ048(13)
End
If |LZ048(14)!=0 or |LZ048(13)!=0
Then
While |LZ048(15)=0
|LZ048(14)->|LZ048(15)
|LZ048(13)->|LZ048(14)
0->|LZ048(13)
End
End
If |LZ048(13)!=0
Then
While |LZ048(14)=0
|LZ048(13)->|LZ048(14)
0->|LZ048(13)
End
End
If |LZ048(16)=|LZ048(15) and |LZ048(16)!=0
Then
2(|LZ048(16))->|LZ048(16)
|LZ048(14)->|LZ048(15)
|LZ048(13)->|LZ048(14)
0->|LZ048(13)
End
If |LZ048(15)=|LZ048(14) and |LZ048(15)!=0
Then
2(|LZ048(15))->|LZ048(15)
|LZ048(13)->|LZ048(14)
0->|LZ048(13)
End
If |LZ048(14)=|LZ048(13) and |LZ048(14)!=0
Then
2(|LZ048(14))->|LZ048(14)
0->|LZ048(13)
End
End
End
If G=34
Then
If |LZ048(13)!=0 or |LZ048(9)!=0 or |LZ048(5)!=0 or |LZ048(1)!=0
Then
While |LZ048(13)=0
|LZ048(9)->|LZ048(13)
|LZ048(5)->|LZ048(9)
|LZ048(1)->|LZ048(5)
0->|LZ048(1)
End
If |LZ048(5)!=0 or |LZ048(1)!=0
Then
While |LZ048(9)=0
|LZ048(5)->|LZ048(9)
|LZ048(1)->|LZ048(5)
0->|LZ048(1)
End
End
If |LZ048(1)!=0
Then
While |LZ048(5)=0
|LZ048(1)->|LZ048(5)
0->|LZ048(1)
End
End
If |LZ048(13)=|LZ048(9) and |LZ048(13)!=0
Then
2(|LZ048(13))->|LZ048(13)
|LZ048(5)->|LZ048(9)
|LZ048(1)->|LZ048(5)
0->|LZ048(1)
End
If |LZ048(9)=|LZ048(5) and |LZ048(9)!=0
Then
2(|LZ048(9))->|LZ048(9)
|LZ048(1)->|LZ048(5)
0->|LZ048(1)
End
If |LZ048(5)=|LZ048(1) and |LZ048(5)!=0
Then
2(|LZ048(5))->|LZ048(5)
0->|LZ048(1)
End
End
If |LZ048(14)!=0 or |LZ048(10)!=0 or |LZ048(6)!=0 or |LZ048(2)!=0
Then
While |LZ048(14)=0
|LZ048(10)->|LZ048(14)
|LZ048(6)->|LZ048(10)
|LZ048(2)->|LZ048(6)
0->|LZ048(2)
End
If |LZ048(6)!=0 or |LZ048(2)!=0
Then
While |LZ048(10)=0
|LZ048(6)->|LZ048(10)
|LZ048(2)->|LZ048(6)
0->|LZ048(2)
End
End
If |LZ048(2)!=0
Then
While |LZ048(6)=0
|LZ048(2)->|LZ048(6)
0->|LZ048(2)
End
End
If |LZ048(14)=|LZ048(10) and |LZ048(14)!=0
Then
2(|LZ048(14))->|LZ048(14)
|LZ048(6)->|LZ048(10)
|LZ048(2)->|LZ048(6)
0->|LZ048(2)
End
If |LZ048(10)=|LZ048(6) and |LZ048(10)!=0
Then
2(|LZ048(10))->|LZ048(10)
|LZ048(2)->|LZ048(6)
0->|LZ048(2)
End
If |LZ048(6)=|LZ048(2) and |LZ048(6)!=0
Then
2(|LZ048(6))->|LZ048(6)
0->|LZ048(2)
End
End
If |LZ048(15)!=0 or |LZ048(11)!=0 or |LZ048(7)!=0 or |LZ048(3)!=0
Then
While |LZ048(15)=0
|LZ048(11)->|LZ048(15)
|LZ048(7)->|LZ048(11)
|LZ048(3)->|LZ048(7)
0->|LZ048(3)
End
If |LZ048(7)!=0 or |LZ048(3)!=0
Then
While |LZ048(11)=0
|LZ048(7)->|LZ048(11)
|LZ048(3)->|LZ048(7)
0->|LZ048(3)
End
End
If |LZ048(3)!=0
Then
While |LZ048(7)=0
|LZ048(3)->|LZ048(7)
0->|LZ048(3)
End
End
If |LZ048(15)=|LZ048(11) and |LZ048(15)!=0
Then
2(|LZ048(15))->|LZ048(15)
|LZ048(7)->|LZ048(11)
|LZ048(3)->|LZ048(7)
0->|LZ048(3)
End
If |LZ048(11)=|LZ048(7) and |LZ048(11)!=0
Then
2(|LZ048(11))->|LZ048(11)
|LZ048(3)->|LZ048(7)
0->|LZ048(3)
End
If |LZ048(7)=|LZ048(3) and |LZ048(7)!=0
Then
2(|LZ048(7))->|LZ048(7)
0->|LZ048(3)
End
End
If |LZ048(16)!=0 or |LZ048(12)!=0 or |LZ048(8)!=0 or |LZ048(4)!=0
Then
While |LZ048(16)=0
|LZ048(12)->|LZ048(16)
|LZ048(8)->|LZ048(12)
|LZ048(4)->|LZ048(8)
0->|LZ048(4)
End
If |LZ048(8)!=0 or |LZ048(4)!=0
Then
While |LZ048(12)=0
|LZ048(8)->|LZ048(12)
|LZ048(4)->|LZ048(8)
0->|LZ048(4)
End
End
If |LZ048(4)!=0
Then
While |LZ048(8)=0
|LZ048(4)->|LZ048(8)
0->|LZ048(4)
End
End
If |LZ048(16)=|LZ048(12) and |LZ048(16)!=0
Then
2(|LZ048(16))->|LZ048(16)
|LZ048(8)->|LZ048(12)
|LZ048(4)->|LZ048(8)
0->|LZ048(4)
End
If |LZ048(12)=|LZ048(8) and |LZ048(12)!=0
Then
2(|LZ048(12))->|LZ048(12)
|LZ048(4)->|LZ048(8)
0->|LZ048(4)
End
If |LZ048(8)=|LZ048(4) and |LZ048(8)!=0
Then
2(|LZ048(8))->|LZ048(8)
0->|LZ048(4)
End
End
End
End
prgmOUTPUT code:
Code:
Text(5,6," ")
Text(5,30," ")
Text(5,54," ")
Text(20,77," ")
Text(20,6," ")
Text(20,30," ")
Text(20,54," ")
Text(20,77," ")
Text(35,6," ")
Text(35,30," ")
Text(35,54," ")
Text(35,77," ")
Text(50,6," ")
Text(50,30," ")
Text(50,54," ")
Text(50,77," ")
If |LZ048(1)!=0
Then
Text(5,6,|LZ048(1))
End
If |LZ048(2)!=0
Then
Text(5,30,|LZ048(2))
End
If |LZ048(3)!=0
Then
Text(5,54,|LZ048(3))
End
If |LZ048(4)!=0
Then
Text(5,77,|LZ048(4))
End
If |LZ048(5)!=0
Then
Text(20,6,|LZ048(5))
End
If |LZ048(6)!=0
Then
Text(20,30,|LZ048(6))
End
If |LZ048(7)!=0
Then
Text(20,54,|LZ048(7))
End
If |LZ048(8)!=0
Then
Text(20,77,|LZ048(8))
End
If |LZ048(9)!=0
Then
Text(35,6,|LZ048(9))
End
If |LZ048(10)!=0
Then
Text(35,30,|LZ048(10))
End
If |LZ048(11)!=0
Then
Text(35,54,|LZ048(11))
End
If |LZ048(12)!=0
Then
Text(35,77,|LZ048(12))
End
If |LZ048(13)!=0
Then
Text(50,6,|LZ048(13))
End
If |LZ048(14)!=0
Then
Text(50,30,|LZ048(14))
End
If |LZ048(15)!=0
Then
Text(50,54,|LZ048(15))
End
If |LZ048(16)!=0
Then
Text(50,77,|LZ048(16))
End
prgmRANDOM code:
Code:
0->X
1->A
While A<=16
If |LZ048(A)=0
Then
1+X->X
A->|LRNDM(X)
End
1+A->A
End
If X=0
Then
3.232->Q
Return
Else
randInt(1,X)->B
|LRNDM(B)->C
2->|LZ048(C)
End