ChipMaster's bwBASIC This also includes history going back to v2.10. *WARN* some binary files might have been corrupted by CRLF.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

98 lines
2.5 KiB

  1. 10 PRINT "TAX DEPRECIATION SCHEDULE"
  2. 20 PRINT
  3. 29 REM - ENTER INITIAL VALUE AND ROUND OFF TO NEAREST CENT
  4. 30 PRINT "PURCHASE PRICE";
  5. 40 INPUT V
  6. 50 V=INT(V*100+.5)/100
  7. 59 REM - ENTER END VALUE AND ROUND OFF TO NEAREST CENT
  8. 60 PRINT "SALVAGE VALUE";
  9. 70 INPUT S
  10. 80 S=INT(S*100+.5)/100
  11. 89 REM - COMPUTE AMOUNT TO DEPRECIATE
  12. 90 D=V-S
  13. 99 REM - ENTER LENGTH OF DEPRECIATION
  14. 100 PRINT "LIFE IN YEARS";
  15. 110 INPUT Y
  16. 119 REM - CHOOSE DEPRECIATION METHOD
  17. 120 PRINT "ENTER 1 FOR SUM OF DIGITS, 2 FOR DECLINING BALANCE";
  18. 130 INPUT X
  19. 140 IF X=2 THEN 450
  20. 150 IF X<>1 THEN 120
  21. 158 REM - BY SUM OF DIGITS METHOD
  22. 159 REM - R1 IS THE CUMULATIVE AMOUNT DEPRECIATED
  23. 160 R1=0
  24. 169 REM - N IS THE PRINTED LINE COUNTER
  25. 170 N=66
  26. 180 PRINT
  27. 190 PRINT
  28. 200 FOR I=1 TO Y
  29. 209 REM - TEST FOR FULL PAGE
  30. 210 IF N<55 THEN 330
  31. 219 REM - FULL PAGE; SPACE TO TOP OF NEXT PAGE AND PRINT HEADINGS
  32. 220 FOR I1=N TO 66
  33. 230 PRINT
  34. 240 NEXT I1
  35. 250 N=7
  36. 260 PRINT " SUM OF DIGITS TAX DEPRECIATION"
  37. 270 PRINT " PRICE $";V
  38. 280 PRINT " SALVAGE VALUE $";S
  39. 290 PRINT " NET DEPRECIATED $";V-S
  40. 300 PRINT " LIFE";Y;"YEARS"
  41. 310 PRINT
  42. 320 PRINT "YEAR","DEPRECIATION","BALANCE"
  43. 329 REM - COMPUTE DEPECIATION AND ROUND OFF TO NEAREST CENT
  44. 330 R=2*D*(Y-I+1)/((Y+1)*Y)
  45. 340 R=INT(R*100+.5)/100
  46. 349 REM - ACCUMULATE DEPRECIATION
  47. 350 R1=R1+R
  48. 360 B=D-R1
  49. 369 REM - TEST FOR COMPLETE DEPRECIATION
  50. 370 IF B>=0 THEN 410
  51. 380 R1=R1+B
  52. 390 R=R+B
  53. 400 B=0
  54. 410 PRINT I,R,B
  55. 420 N=N+1
  56. 430 NEXT I
  57. 440 GOTO 700
  58. 448 REM - BY DECLINING BALANCE METHOD
  59. 449 REM - ENTER DECLINING BALANCE PERCENT
  60. 450 PRINT "METHOD IN %";
  61. 460 INPUT M
  62. 469 REM - CONVERT PERCENT TO DECIMAL
  63. 470 M=M/100
  64. 479 REM - N COUNTS THE LINES PRINTED ON EACH PAGE
  65. 480 N=66
  66. 489 REM - R IS THE AMOUNT LEFT TO DEPRECIATE
  67. 490 R=D
  68. 500 PRINT
  69. 510 FOR I=1 TO Y
  70. 519 REM - TEST FOR A FULL PRINTED PAGE
  71. 520 IF N<55 THEN 650
  72. 529 REM - FULL PAGE; SPACE TO TOP OF NEXT PAGE AND PRINT HEADINGS
  73. 530 FOR I1=N TO 66
  74. 540 PRINT
  75. 550 NEXT I1
  76. 560 N=8
  77. 570 PRINT " DECLINING BALANCE TAX DEPRECIATION"
  78. 580 PRINT " PRICE $";V
  79. 590 PRINT " SALVAGE VALUE $";S
  80. 600 PRINT " NET DEPRECIATED $";D
  81. 610 PRINT " LIFE";Y;"YEARS"
  82. 620 PRINT " METHOD ";M*100;"%"
  83. 630 PRINT
  84. 640 PRINT "YEAR","DEPRECIATION","BALANCE"
  85. 649 REM - COMPUTE DEPRECIATION AND ROUND OFF TO THE NEAREST CENT
  86. 650 R1=INT((R*M/Y)*100+.5)/100
  87. 659 REM - ACCUMULATE REMAINING BALANCE
  88. 660 R=R-R1
  89. 670 PRINT I,R1,R
  90. 680 N=N+1
  91. 690 NEXT I
  92. 700 PRINT
  93. 709 REM - RESTART OR END PROGRAM?
  94. 710 PRINT "MORE DATA?(1=YES, 0=NO)";
  95. 720 INPUT X
  96. 730 IF X=1 THEN 20
  97. 740 END