@GrabSomeEyes

Umm, no. DATA is completely unrelated to Subroutines. Also, there is no local variables/return value either.

I don't know if this is an improvement, but here is my "fixed" Money Display Routine. Warning: It's advanced programming. Well, as advanced as BASIC programming can be.

MONEY DISPLAY

DIM K[6]

S$=" ":M=1000

INPUT "TRILLION,BILLION,MILLION,THOUSAND,DOLLAR,CENT",K[5],K[4],K[3],K[2],K[1],K[0]

P=0:?">";:FOR I=5 TO 1 STEP -1

IF P THEN ?",";RIGHT$(STR$(M+K[I]),3); ELSE IF K[I] THEN ?RIGHT$(S$+"$"+STR$(K[I]),3); ELSE ?S$;

P=P+K[I]:NEXT:?".";RIGHT$(STR$(M+K[0]),2)

It is

1. Extensible (as many K[] as you like!)

2. Includes CENTS

3. Moving dollar sign

4. FITS IN ONE LINE!!!

Good luck integrating it into your program. You may need to split it into two lines as I did some compressing to fit it into one line. You need to check 3 different values, so I suggest to split between P==0 and P!=0.