1 REM "COMMISSION.BAS" by Robert S. Blacher (August, 1983)
2 REM Program compares commissions charged by Merrill Lynch and

  Charles Schwab
5 CLEAR
7 INPUT "(B)UY, (S)ELL, OR (Q)UIT";Q$: IF Q$ ="Q" THEN PRINT "GOODBYE!": GOTO 600
10 INPUT "HOW MANY SHARES";N
20 INPUT "PRICE PER SHARE";P
30 D=N*P
100 REM MERRILL LYNCH
105 IF D<300 THEN C=D*.1: GOTO 180
110 IF N>=101 THEN GOTO 200
140 IF D <801 THEN C=8.43+(D*.02696): GOTO 180
145 IF D < 2501 THEN C=16.85+(N*.0315)+(D*.01685):GOTO 180
150 IF D< 5001 THEN C=29.21 +(N*.0315)+ (D*.01236):GOTO 170
155 IF D < 20001 THEN C=31.46 +(N*.0315) + (D*.01236): GOTO 175
160 IF D>=20001 THEN C=92
161 GOTO 180
170 IF C>87 THEN X=87 ELSE X=C
171 GOTO 300
175 IF C>92 THEN X=92 ELSE X=C
176 GOTO 300
180 X=C:GOTO 300
200 IF D <801 THEN C=8.43+(N*.0785)+(D*.02696): IF C>D*.1 THEN C=D*.1:GOTO 270
205 IF D < 2501 THEN C=18.95+(N*.0893)+(D*.01685): GOTO 270
210 IF D< 5001 THEN C=31.31 +(N*.0893)+ (D*.01236):GOTO 270
215 IF D < 20001 THEN C=33.56 +(N*.0945) + (D*.01236):GOTO 270
220 IF D< 30001 THEN C=114.45 +(N*.0945) + (D*.00843): GOTO 270
225 IF D < 300001! THEN C= 199.84 +(N*.0945) +(D*.00562): GOTO 270
230 IF D>= 300001! THEN C= 1209.86 + (N*.0945) +(D*.00225)
270 IF D<=5000 THEN X=N*.87 ELSE X=N*.92
300 IF D>300 THEN M=30 ELSE M=0
310 PRINT "****** MERRILL LYNCH ******"
320 IF C<M THEN C=M
330 IF C>X THEN C=X
335 PRINT "COMMISSION = $";:PRINT USING "######.##";CDBL(C)
340 PRINT "AMOUNT = $";:PRINT USING "######.##";CDBL(D)
350 IF Q$="S" THEN T = D - C ELSE T=D + C
360 NETP=T/N
370 PRINT "NET AMOUNT = $";:PRINT USING "######.##";CDBL(T)
380 PRINT "NET PRICE PER SHARE = $";NETP
390 PRINT "COMMISSION PER SHARE = $";:PRINT USING "######.###";C/N
395 ML=C
400 REM SCHWAB COMMISSION
440 IF D <3001 THEN C=18+(D*.012): GOTO 470
450 IF D < 7001 THEN C=36+(D*.006): GOTO 470
460 IF D>= 7001 THEN C= 57 + (D*.003)
470 IF N<=600 THEN M=N*.08 ELSE M=48 + (N-600)*.04
480 IF N>=100 THEN X=N*.45 ELSE X=C
485 PRINT "****** SCHWAB ******":
490 IF C<M THEN C=M
495 IF C>X THEN C=X
500 PRINT "COMMISSION = $";: PRINT USING "######.##";CDBL(C)
505 PRINT "AMOUNT = $";:PRINT USING "######.##";CDBL(D)
510 IF D>56000! THEN PRINT "AMOUNT OVER $56,000. CALL SCHWAB FOR QUOTE.":GOTO 5 
520 IF Q$="S" THEN T=D-C ELSE T=D+C
525 NETP=T/N
530 PRINT "NET AMOUNT = $";:PRINT USING "######.##";CDBL(T)
535 PRINT "NET PRICE PER SHARE = $";NETP
538 PRINT "COMMISSION PER SHARE = $";:PRINT USING "######.###";C/N
539 IF ML>C THEN DIF=ML-C ELSE DIF=C-ML
540 PRINT "***********": PRINT "DIFFERENCE = $";DIF;,"PER SHARE = $";DIF/N
545 PRINT "***********"
547 IF ML>C THEN PRINT "SCHWAB WINS" ELSE PRINT "MERRILL LYNCH WINS"
548 IF ML>C THEN W=100*DIF/C:PRINT "MERRILL LYNCH COMMISSION IS GREATER BY";W;"PER CENT"  ELSE W=100*DIF/ML: PRINT "SCHWAB COMMISSION IS GREATER BY";W;"PER CENT"
549 PRINT "***********"
550 GOTO 5
600 END
 CENT"  ELSE W=100*DIF/ML