home *** CD-ROM | disk | FTP | other *** search
/ Amiga ISO Collection / AmigaDemoCD2.iso / DEMOS / PTK-BS32.DMS / in.adf / TXTdata / BBCcoding.txt < prev    next >
Encoding:
Text File  |  1977-12-31  |  2.1 KB  |  99 lines

  1. <>
  2. @3{PROGRAMMING HIGH-TECH MACHINES, SUCH AS THE BBC
  3. @4}by Converse of A.F
  4. @1
  5. Hi,  welcome  to Amiga Frontier.  Err,
  6. bollox,  wrong  mag.
  7. Aaannyyway,  I've  ventured out of A.F
  8. to  lend  a  hand  to  the creators of
  9. B.S.E.   Beyond  Chastity,  or  summit
  10. like  that!   Just kidding guys.  I'll
  11. be  waffling on about BBC programming,
  12. but you know as well as I do that I'll
  13. end  up  rambling  on  about something
  14. else  at  the  end  of the article.  I
  15. s'ppose  just  about  everyone reading
  16. this  mag  has  access to a crappy BBC
  17. micro  in  school.  So, assuming this,
  18. here's a little program to impress yer
  19. mates  with,  if you have any that is.
  20. @6
  21.                -=-=-=-
  22. @1
  23. Here's a rather rude division program,
  24. which  should  work.   But seeing as I
  25.  
  26.  
  27.  
  28.  
  29. haven't  used a BBC before, I can't be
  30. sure.    But  hey!   It  works  on  my
  31. Electron....
  32. @5
  33.  5   REM Another shyte program by
  34.          Converse of A.F
  35.  10  DIM Q% 100
  36.  20  FOR I=0 TO 3 STEP 3
  37.  30  P% = Q%
  38.  40  [OPT I
  39.  50  .Start CLD
  40.  60  LDY # 8
  41.  70  .Loop ASL &72
  42.  80  ROL &73
  43.  90  LDA &73
  44.  100 BCC Label
  45.  110 SBC &71
  46.  120 STA &73
  47.  130 SEC
  48.  140 JMP Shift
  49.  150 .Label SEC
  50.  160 SBC &71
  51.  170 BCC Shift
  52.  180 STA &73
  53.  190 .Shift ROL &70
  54.  200 DEY
  55.  210 BNE Loop
  56.  220 RTS
  57.  230 ]
  58.  240 NEXT
  59.  250 INPUT "Numerator "numerator%
  60.  260 INPUT "Denominator "denominator%
  61.  270 P% = &71
  62.  280 [OPT 3
  63.  290 EQUB denominator% 
  64.  300 EQUW numerator%
  65.  310 RTS
  66.  320 ]
  67.  330 CALL Start
  68.  340 Print "Quotient is ";?&70
  69.  350 Print "Remainder is ";?&73
  70. @1[7
  71. Yes,  yes,  yes!   I know it's useless
  72. crap, but I'm a bit crap when it comes
  73. to programming.
  74. In the next issue of Beyond Chastity I
  75. will  be  showing  you  a  rather rude
  76. Basic  program  which  will stop nosey
  77. gits  from  being  able  to  read your
  78. program,   dead   easy   only   a  few
  79. lines....   Hang  on...  What's that I
  80. hear  you  say?  Why don't I ever give
  81. programming  listings  in  A.F?   Err,
  82. probably cos I don't want to spoil our
  83. reputation  and make us seem "clever".
  84. (even  though  we're not) It's strange
  85. writing  for  other  mags,  especially
  86.  
  87.  
  88.  
  89.  
  90.  
  91.  
  92.  
  93.  
  94.  
  95.  
  96.  
  97. when  you're  only  writing little art
  98. tickles.   Well,  I'll  see you in the
  99. next issue....  maybe.