View Full Version : use pbasic to divide the 2345 number into 4 individual number 2,3,4,5
hsiaochung
08-17-2008, 08:41 PM
I have a number 2345
how can i divide the 2345 number into 4 individual number 2,3,4,5
which command in PBasic can do above function
Mike Green
08-17-2008, 08:48 PM
The operator DIG. Look in the PBasic Manual index.
hsiaochung
08-17-2008, 09:16 PM
Thanks Mike
how could i transfer a num to its ASCII
such as 0 its ascii code is 48
which operator can do that
Post Edited (hsiaochung) : 8/17/2008 2:55:16 PM GMT
PJ Allen
08-17-2008, 09:19 PM
The ASCII code for "0" is $30, "1" is $31, "2" is $32...· Noticing a pattern?
Mike Green
08-17-2008, 09:40 PM
Add "0" or $30 like
(2345 DIG 1) + "0"
hsiaochung
08-17-2008, 09:52 PM
Thanks for Mike again
I use the below statements
(2345 DIG 1) + 48