i imitated the deck of cards routine and i generated a Domain error at the closing parenthases on the first sub() command i am using a TI 84+
help!!!!!!!!!!!!!!!!!!!!!!!
Forum
» Programming & Design / TI-83/84/+/SE Programming
» help!!!!!!!!!!!!!!!!!!!!!!!
Summary:
deck of cards
help!!!!!!!!!!!!!!!!!!!!!!!
larry4624 15 Aug 2008 21:09
sub ? why are you using strings for cards? is this assembly or basic?
Visit Calccrypto for info on crypto
KC2ZOF
See the Deck of Cards routine.
i use a different way of shuffling cards. It takes a bit longer
Visit Calccrypto for info on crypto
KC2ZOF
It works fine for me, so make sure you didn't make a typo. Specifically, make sure the string "A23456789TJQK" appears exactly like that on your calculator.
EDIT: Nevermind, i just don't know what i am asking
i found my own way of doing that now
Would you mind sharing it?
i think it takes more memory this way:
:ClrHome
:"A23456789TJQK"→Str1
:"SDCH"→Str2
:Lbl 0
:int(rand*13→A
:If A<1
:Goto 0
:Lbl 1
:int(rand*4→B
:If B<1
:Goto 1
:Disp "Value:" + sub(Str1,A,1)
:Disp "Suit:" + sub(Str2,B,1)
:Pause
:ClrHome
/forum/t-81851/help#post-