home *** CD-ROM | disk | FTP | other *** search
/ Publication 11 / Publication_11_19xx_-_de_Side_B.d64 / seq-packer (.txt) < prev    next >
Commodore BASIC  |  2023-02-26  |  835b  |  28 lines

  1. 10 input"p[146]acken,oder e[146]ntpacken ";a$:ifa$<>"p"anda$<>"e"thenprint"[145][145]":goto12
  2. 11 ifa$="e"then20
  3. 12 input"source-name ";s$:input"destination-name ";d$
  4. 13 x=0:b$="":x$=""
  5. 14 open2,8,2,s$+",s,r":open1,8,1,"@:"+d$+",s,w"
  6. 15 get#2,a$
  7. 16 ifa$=b$thenx=x+1:x$="\"+str$(x)+b$:goto15
  8. 17 print#1,x$:x$=a$:b$=x$:x=0
  9. 18 ifb$<>"\"then15
  10. 19 print#1,"\":close2:close1:print"packed !":end
  11. 20 input"destination-name ";d$
  12. 21 open2,8,2,d$+",s,r"
  13. 22 input#2,a$:ifa$="\"thenclose2:end
  14. 23 ifleft$(a$,1)="\"then27
  15. 24 printa$;
  16. 25 geta$:ifa$=""then22
  17. 26 geta$:on-(a$="")goto26:goto22
  18. 27 x=val(mid$(a$,2,len(a$)-1)):x$=right$(a$,1):forg=1tox+1:printx$;:next:goto22
  19. 28 rem
  20. 29 rem ********************************
  21. 30 rem *                              *
  22. 31 rem *  seq - packer / - entpacker  *
  23. 32 rem *                              *
  24. 33 rem *  coded by zeitgeist/h-t/wil  *
  25. 34 rem *      for publication 11      *
  26. 35 rem *                              *
  27. 36 rem ********************************
  28.