Breakeven Analysis

Author(s): Mel Routt
Publication: Syntax
Pub Details: Syntax/Syntax ZX80 v3 n1 (Volume 3, Issue 1)
Date: January 1982
Pages: 4-6

This program requires only a single video format for all control data input with an option to erase and re-enter data. This option occurs just before computation, which doesn’t begin until you approve data entries.

The computational mode in the book from which I adapted this program (BASIC Computer Programs for Business, Vol.1, reviewed this page) required a STEP function. Although the 8K ROM provides this function, I replaced it with a counter and IF-THEN GOTO loop; note lines 365 and 370.

All underlined items are inverse graphics. Enter the program, then type RUN to start. Enter total fixed costs and variable costs per unit. When you complete the control data input and approve it, the screen goes blank for a while. Be patient. The time varies with the input data.

If you requested a long table, you will require more time and overflow the display area, getting an error 5. Have no fear–just press CONT (continue) and NL each time the screen fills until you reach the end of your table or memory, whichever occurs first.

Try to borrow or buy a copy of the book this program comes from and use their data input. Your results should nearly match theirs.

List of Variables: A=profit or loss
F=fixed costs        C=total costs
P=unit price     C0=breakeven costs
Q0=breakeven point/qty
Q1=start qty        R=total revenues
Q2=stop qty    R0=breakeven revenue
 S=table increment (step)
 U=unit cost        V=variable cost
V1=total variable cost
   1 REM "PROFLOSS TABLE"
2 REM BY MEL ROUTT, 10/3/81
3 REM ADAPTED FROM PG 69
4 REM "BASIC COMPUTER PROGRAMS FOR BUSINESS, VOL. 1"
5 REM BY CHARLES D. STERNBERG
6 REM COPYRIGHT 1980
7 REM BY PERMISSION MR MADARAS
8 REM HAYDEN BOOK CO.
9 REM ROCHELLE PARK, NJ 07662
10 CLS
15 PRINT
20 PRINT "PROFIT/LOSS/BREAKEVEN TABLE"
25 PRINT
30 PRINT " ENTER CONTROL DATA:"
35 PRINT
40 PRINT "FIXED COSTS:";TAB 21;"$";
45 INPUT F
50 PRINT F
55 PRINT
60 PRINT "VARIABLE COSTS:";TAB 21;"$";
65 INPUT V
70 PRINT V
75 PRINT
80 PRINT "UNIT PRICE:";TAB 21;"$";
85 INPUT P
90 PRINT P
95 PRINT
100 PRINT "START QTY OF TABLE:";TAB 22;
105 INPUT Q1
110 PRINT Q1
115 PRINT
120 PRINT "STOP QTY OF TABLE:";TAB 22;
125 INPUT Q2
130 PRINT Q2
135 PRINT
140 PRINT "INCREMENT TABLE BY:";TAB 22;
145 INPUT S
150 PRINT S
155 PRINT
160 PRINT
165 PRINT "IF DATA CORRECTION REQ/D TYPE ""YES"" AND ""N/L""."
170 PRINT
175 PRINT "IF DATA OK PRESS ""N/L""."
180 INPUT D$
185 IF D$="YES" THEN GOTO 10
190 CLS
195 PRINT " PROFIT/LOSS(-)/BREAKEVEN TABLE:"
200 PRINT
205 PRINT "RUN";TAB 7;"JOB";TAB 15;"REV.";TAB 22;"PROF";TAB 27;"UNIT"
210 PRINT "QTY";TAB 7;"COST";TAB 22;"LOSS";TAB 27;"COST"
215 FOR I=1 TO 32
220 PRINT "=";
225 NEXT I
230 LET Q0=F/(P-V)
235 LET X=Q0
240 GOSUB 700
245 LET Q0=X
250 LET R0=P*Q0
255 LET X=R0
260 GOSUB 700
265 LET R0=X
270 LET Q=Q1
275 LET C0=F+(V*Q0)
280 LET X=C0
285 GOSUB 700
290 LET C0=X
295 LET V1=V*Q
300 LET R=P*Q
305 LET C=F+(V*Q)
310 LET U=C/Q
315 LET X=U
320 GOSUB 700
325 LET U=X
330 LET A=R-C
335 IF Q<Q0 THEN GOTO 360
340 GOSUB 600
345 PRINT Q0;TAB 7;C0;TAB 15;R0;TAB 23;"BREAKEVEN"
350 GOSUB 600
355 LET Q0=999999999999
360 PRINT Q;TAB 7;C;TAB 15;R;TAB 22;A;TAB 27;U
365 LET Q=Q+S
370 IF Q<Q2+S THEN GOTO 295
375 PRINT
380 PRINT "TOTAL VARIABLE COSTS: $";V1
385 PRINT
390 PRINT "IF YOU WISH TO RUN NEW DATA TYPE ""YES"" AND ""N/L""."
395 PRINT
400 PRINT "IF NOT PRESS ""N/L""."
405 INPUT D$
410 IF D$="YES" THEN GOTO 10
415 PRINT
420 PRINT "IT WAS A PLEASURE TOSERVE YOU."
425 STOP
600 FOR I=1 TO 32
605 PRINT "-";
610 NEXT I
615 RETURN
700 LET X=(INT (100*(X+.005)))/100
705 RETURN
Syntactic Sum: 45638, 8K

Note: Type-in program listings on this website use ZMAKEBAS notation for graphics characters.