Can I fix a 40 year old Sinclair ZX80 bug?

Поділитися
Вставка
  • Опубліковано 18 кві 2024
  • I wrote a game back in 1982 that really needs improvement. Can I fix it, and make something even better now?
    Video examining the code to the Golf 2024 game: • ZX80 Golf 2024 code wa...
    To get early ad-free access to new videos, or your name at the end of my videos, please consider supporting me from just $1 or 80p a month at / bigcar
    Link to my other channel - Big Car:
    / bigcar2
    #littlecar
  • Наука та технологія

КОМЕНТАРІ • 101

  • @LittleCar
    @LittleCar  2 місяці тому +9

    Walkthrough of the code for the new game - Golf 2024: ua-cam.com/video/EyKLj9Da5P8/v-deo.html

  • @benc8386
    @benc8386 Місяць тому +52

    LET SHOT=RND(5) is a remarkably accurate physical simulation of my actual golf game.

  • @NeroVingian40
    @NeroVingian40 Місяць тому +18

    The thing I like the most about you was how you are both a car and a tech nerd lol

  • @rodoherty1
    @rodoherty1 Місяць тому +16

    Please start up the LittleCoding channel and post more videos like this.

  • @MarcKloos
    @MarcKloos Місяць тому +4

    My first micro was a ZX Spectrum 16k (after a 2 week drama with a half broken ZX81) and it got me into my computer career.
    Some 10 years ago I started collecting Spectrums, clones and assorted Sinclair stuff and now I have a huge connection, a little museum in the mencave even. I wish I would have the skills to have an interesting talk about each of them to make a UA-cam channel out of it, but more than "hey look, this is a Spanish Spectrum, the keyboard looks slightly different" I wouldn't know what to tell an audience! Some people just have the skills to talk very engaging about mundane subjects. Tech Moan is also such an example!

  • @Grid56
    @Grid56 Місяць тому +4

    Oh the memories....ZX81 , BBC Micro, BBC Master, Amiga 500+. ...Typing in BASIC programs from the magazines around at the time, then spending the rest of the time fixing them when they didn't work. The best way to learn. Stood me in good stead for a career on mainframes. The 81 could be annoying as just as you got loaded, the ram would fall off the back and crash....Cue the velcro!

  • @glonch
    @glonch Місяць тому +11

    Awesome video - well done!... My mother was really into Search-A-Word puzzles... she would always do the one in the Sunday papers. When I was about 14 or so, I saw her doing the puzzle and I thought "I could make a program that could solve those", off to my Apple //c and started writing. I got wrapped around the axle about halfway through it and shelved the project. Fast forward a few years to when I was working the night shift with not much to do, I dusted off the program and after a few hours had it working. It would read in a text file with the grid and words and would print out on screen or paper the beginning/ending coordinates of each work (I didn't bother with any graphical 'circling' of the words, etc). Fast forward another 30 years and the only thing I had left was a printout of the program. After OCR, text editing, it came back to life. It was a stupid program, but it taught me a ton about logically figuring out a problem and having the computer solve it.

  • @fredsmith1970
    @fredsmith1970 Місяць тому +5

    Yay - Sinclair basic from the 80's... brings back the memories 🙂

    • @monteceitomoocher
      @monteceitomoocher Місяць тому

      Sure does, i built this from a kit and had a lot of fun with it, wish i hadn't binned it along the way!.

  • @chrispenn715
    @chrispenn715 2 дні тому

    Ah! Brings back memories of my hacking away with a zx81. Helped me in my career a few years later! I got a management job in an office that was being computerized. Every other manager was much older and terrified of computers. I just piled in😂

  • @IanHodgetts
    @IanHodgetts Місяць тому +1

    Very nostalgic. I too started programming early (age 10) but on a ZX81. That at least had the capabilities for some better screen refreshing and I managed to write a few games for myself even in 1K. I soon progressed to the infamously wobbly 16K RAM pack ;-)

  • @MartinIbert
    @MartinIbert Місяць тому +8

    Thanks for this, it was fascinating to watch! I started my coding journey at around that age too, but with my father's PET 2001. My father was very forward-thinking in letting his sons play with a seriously expensive machine that he used to feed our family. That was the foundation for my carreer in IT. Which so far (I am 57 now) has been reasonably successful.

    • @Lensman864
      @Lensman864 Місяць тому +2

      I love the 2001 series Commodore PET. I used them at my further education college in Newcastle back in 1982. To this day they LOOK like a computer should even if the keyboard was ... challenging.

    • @MartinIbert
      @MartinIbert Місяць тому

      @@Lensman864 My dad had the keyboard replaced by something sensible that spanned the whole front of the thing, and the datasette was relagated to an extra housing.
      I don't want to know what that modification cost.

    • @alanclarke4646
      @alanclarke4646 Місяць тому

      We had PETs at college. I loved the sloping sides to the monitor casing!

  • @AdamJRichardson
    @AdamJRichardson Місяць тому +1

    Cut my coding teeth on a ZX81, must have been in 1982, so this brought back fun memories! I remember painfully typing in games from magazines, with 0% success rate lol

  • @JenniferinIllinois
    @JenniferinIllinois Місяць тому +2

    Ah that takes me back. BASIC programing on the Commodore 64 was my thing back in the day. Definitely a whole lot more available than on your ZX80. 😉

  • @kevinsmith9899
    @kevinsmith9899 Місяць тому +3

    Thanks for the fun trip down memory lane. I still have a print-out of a dungeon crawl I wrote in BASIC at around the same time that you were working on your golf game. I wasn't quite as constrained, as my Sol-20 computer had a bit more memory available, and I used a more powerful version of BASIC (NorthStar). It was a lot of fun to code back then, even if we weren't very skilled at it.

  • @davewaterworth8846
    @davewaterworth8846 26 днів тому +1

    I didn't realise the ZX80 had a ram expansion - I knew the ZX81 did, along with the much curse crashes due to the design making it prone to the dreaded wobble crash!

  • @cedley1969
    @cedley1969 Місяць тому +1

    ZX81 was my first, I think the scope of what you had taught more elegant programming, frugal equals efficiency.

  • @kevinobrien5450
    @kevinobrien5450 Місяць тому +1

    My first programming experience was a Research Machines RML380Z at school. We had to book time on it as there was only 1. Shortly after that I got a ZX81, then a VIC-20, then a CBM-64. By that point the ZX Spectrum and BBC Micros were out. School invested in a lab of networked BBC Micros. Went to university and used DEC VAX and IBM PC clones. Bought myself an Atari ST and used that for some of my college work. Fun memories.

  • @Bicyclehub
    @Bicyclehub Місяць тому +1

    This was surprisingly good fun! I did a lot of programming with Basic in 2007. I needed to do some extensive calculations and remembered all the Basic functions from a college course in 1980. It’s a very intuitive language and can do some quite powerful things.

  • @rusty911s2
    @rusty911s2 Місяць тому

    Excellent! Really enjoyed that, thank you.
    Just looked it up, £99 in 1980 is over £530 today. Just look at what computimg power (or any other home tech) you could get for that now.

  • @Lensman864
    @Lensman864 Місяць тому +5

    The World's Greatest Adventure Game!
    10 PRINT "Welcome to the world's greatest adventure game: you are a great warrior!"
    20 PRINT
    30 PRINT "You are in a dark place. What is your command mighty warrior?"
    40 INPUT A$
    50 CLS
    60 PRINT "I'm sorry. I didn't understand that."
    70 GOTO 30

    • @LittleCar
      @LittleCar  Місяць тому +1

      😂

    • @melkiorwiseman5234
      @melkiorwiseman5234 Місяць тому

      That's even better than "Doctor Z" where it asks you about 5 randomly selected pseudo-psychological questions, ignores your answers and then says that you're making a real effort to solve your problems and asks you when would be a good time for another appointment. Again, it ignores your answer and just says that would be fine. 😅

  • @majormojo
    @majormojo Місяць тому

    Love it! As a fellow recovering programmer with an interest in vintage computing, this is a fun diversion from the car content. 10/10 recommended. Cheers!

  • @thatcheapguy525
    @thatcheapguy525 Місяць тому +3

    closest thing I got to a ZX80 was a Texas Instruments TI30 LED Scientific calculator (not enough pocket money) which in itself was a massive leap at the time. fascinating how with a bit of experimentation and plain butchery I got it to play synth type sounds through a speaker where each number pressed on the keypad produced a different 'note.'
    15 years later I was using Cubase an Atari ST in my home studio to link a Boss Dr Rhythm, Yamaha keyboard and Tascam 8-track to very unconventionally create heavy rock music. amusing looking back now...

    • @Lensman864
      @Lensman864 Місяць тому +3

      It's a little known fact that the ZX80 can be coerced into making tunes.
      Set up some different sized loops and place a small radio on top of the ZX80. Tune the radio until you hear the CPU cycles (via the Z80A's extensive r.f leakage) and when the loops are triggered it'll play pitches.

    • @thatcheapguy525
      @thatcheapguy525 Місяць тому +2

      @@Lensman864 lol. old high tech was certainly something for the creative mind in quite unintended ways.

  • @zappababe8577
    @zappababe8577 15 днів тому +1

    My ex insulted me once by saying that I was like a ZX, in that I only had 1K of RAM! Although at another time he said, "You look stupid, but you're quite clever really".

  • @rome0610
    @rome0610 Місяць тому +2

    Looking through my old code (I preferred PASCAL) I mostly think "What the heck I was thinking at this?!"😜

  • @Jimyjames73
    @Jimyjames73 Місяць тому

    I had a Sinclair ZX81 for my 1st Computer, then I went on to have a Sinclair Spectrum Plus - yeah I used to like to do some programming for both computers - I used to buy 'Your Sinclair' & 'Sinclair User' & spend hrs just copy the programmes from the Magazines to my Computer, Then I used to save it on to my ZX Microdrives!!! 😉🚂🚂🚂

  • @g6otu
    @g6otu Місяць тому

    Love your car videos,
    would be great to see some long format videos from you in the 80s/90/s computing genres.

  • @mrjsv4935
    @mrjsv4935 Місяць тому

    Nice Basic programming and update to your old game :)
    I still have my first computer too from the 80's, a "Finnish" Salora Manager, which was known elsewhere as Vtech Laser 2001, and used to type in games from computer magazine program lists for this computer. Later got Commodore 64 and did the same thing, but sold the C-64 in 1991. Now I have the Mini C-64, which doesn't have working physical keyboard, but I have external usb keyboard, which works with it.
    Have been thinking of trying out some Basic programming with these, but for the Salora, tape drive condition is terrible, so I have no way to save the program.
    Mini C-64 could save it, but Commodore special characters present a problem, as the modern usb keyboard obviously doesn't have them marked, so I'd have to try and test every one of them.

  • @thomasfrancis5747
    @thomasfrancis5747 Місяць тому +2

    Blimey a working ZX80. Many years ago I bought one at a car boot sale for £1 and promptly sold it for £200 - they're worth even more now. First programming I worked with was Star Trek in Cobol on a university mainframe in 1979 using punched cards but my first micro was a Video Genie TRS-80 clone - not bad for its time. Wonder how kids these days would get on with Basic.

    • @paulsengupta971
      @paulsengupta971 Місяць тому

      ZX Basic and those of other 1980s microcomputers was a fantastic start for a lot of people into computing, including myself. An interpreter which was active as soon as you switched the thing on meant simplicity in getting started, and you could progress to machine code/assembly language quite easily as well. This has all been lost these days.
      LET EGGS = 48...

  • @Robert08010
    @Robert08010 Місяць тому

    If you added to this, it could be playable. Imagine each hole may take 1 or multiple swings, each time may result in landing in the rough or a sand trap or on the green or in the hole, etc. but not just at random. You could incorporate something like the old lunar lander program or the "gorillas.bas" program where for each swing you enter in a angle and strength. Or maybe an angle and a club. For it to continue to be playable, you might have a database of variously shaped holes and then randomize the order of the hole data at the beginning of each game.

  • @8_Bit
    @8_Bit 2 місяці тому +1

    That's really cool that you had a game published in a magazine way back then! I suppose the magazine editor called it a "program" rather than game because there wasn't much interactivity? :) (also interesting that they didn't use the "programme" spelling). Your 2024 update is (of course) a huge improvement with actual gameplay. Fun stuff, thanks for sharing.

    • @LittleCar
      @LittleCar  2 місяці тому +3

      "Program" was in common usage in the UK at that time for a computer listing (even games), and has stuck.
      dictionary.cambridge.org/dictionary/english/program

    • @8_Bit
      @8_Bit 2 місяці тому +1

      @@LittleCar Cool. For whatever reason here in Canada, educators and journalists (and whoever else was writing about computers) often continued to use the "programme" spelling for computer programs. I guess they didn't know even the UK wasn't sticking to that!

  • @UncleJoeLITE
    @UncleJoeLITE Місяць тому +1

    Thanks Andy, I forgot no arrays on ZX, but a decent work around. I also use emulators for most of my collection, just check/test them every year. The 68020 Amiga 500+++ with Gotek gets used a bit. My oldest pc atm is a 1983 VIC-20 ('3583 Bytes Free' is not overkill) & a rare Welsh Dragon 32, but no ZXs.
    I did look at ZX81 before buying a VIC, but even back in the Middle Ages the ZX was primitive.

    • @LittleCar
      @LittleCar  Місяць тому +2

      As my parents got the ZX80, and as Sinclair was so big in the UK, I was on the Sinclair track all the way until I got an Atari ST. But yeah, not the best quality.

  • @yasua7000
    @yasua7000 Місяць тому

    Golf 2024 looks like an early, text only version of Lee Carvallo's Putting Challenge.

  • @OneOfThePetes
    @OneOfThePetes Місяць тому +3

    Wooo BASIC!
    :)

  • @darrensmith6999
    @darrensmith6999 Місяць тому

    God i remember getting my ZX Spectrum Pluss in 1985 mainly for the games it supported and spent many a happy hours playing them.
    I used to get all the Specky magazines and spent a lot of time typing in these programs from the mags, only to find at the end that they didn't work Haha (:

  • @zapod20
    @zapod20 Місяць тому

    Nice bit of nostalgia there. I sent a ZX Spectrum program to the cassette magazine 16/48 - an ambitious wordsearch generator where you keyed in some words and it laid them out randomly on a grid. I tried to write an algorithm where words with shared letters would overlap but it never worked properly on the diagonal words. The editor of 16/48 wrote a very kind letter pointing out this bug and the program never got published… oh well.

    • @LittleCar
      @LittleCar  Місяць тому

      I remember that magazine! Free cassette on every cover if I remember.

  • @guepar58
    @guepar58 Місяць тому +2

    I'm quite sure I copied it on my Timex Sinclair 1000 !!

  • @zx85
    @zx85 Місяць тому

    I'm impressed that you got all that into 1K 🙌🏻👏🏻

    • @LittleCar
      @LittleCar  Місяць тому +2

      Not the new game - that was more like 4K.

    • @zx85
      @zx85 Місяць тому

      @@LittleCar 1K really was quite the constraint wasn't it - 11 year old Little Car did well to fit it in.
      We considered ourselves lucky to get a wobbly 16K RAM pack for our ZX81.. wouldn have been little more than a novelty without it...

    • @paulsengupta971
      @paulsengupta971 Місяць тому +1

      I used to be able to write a lunar lander game in 1K on the ZX81. I never bothered saving it, I just typed it in again from memory (or making it up as I went along) each time. Someone in school saw me do that one day and was absolutely astonished that I got that game into 1K!

  • @martinstephenson2226
    @martinstephenson2226 Місяць тому

    I wrote a basic game of solitair (patience) on the ZX80 in my youth using the rand function to generate a random deck of cards to deal and draw from. Must've been around 15 (now in my 60's). Became a civil engineer though not a progammer

  • @carlstevenwilletts
    @carlstevenwilletts Місяць тому

    Anyone remember the Input magazine from the early 1980's? I would spend a long time typing in the included programs on my Commodore Vic 20 only to find that a lot of them had errors. :D

  • @stuartmcconnachie
    @stuartmcconnachie Місяць тому

    It would be fairly easy to loop around the shots on each hole. So for a 3 on a hole you’d see…
    The ball is in the rough
    The ball is on the green
    The ball is in the hole

  • @brighb
    @brighb Місяць тому

    Related but unrelated, would love to see one of your videos on the Sinclair C5!

  • @jasejj
    @jasejj Місяць тому +1

    You could have used a series of sub routines for the if-then conditions, and called them using "GO SUB 400+10*Z" - I believe Sinclair basic allows you to do that.
    I think you could probably use TL$ and TR$ to slice up a single string containing all five option strings and use that to print out in a few lines of BASIC - something like
    LET OUT$=""
    FOR X=1 TO (Z-1)*L
    LET OUT$=TL$(OUT$)
    NEXT X
    FOR X=1 TO (5-Z)*L
    LET OUT$=TR$(OUT$)
    NEXT X
    PRINT OUT$
    Yes I know this is taking it to extremes but it demonstrates that it can, technically be done!

    • @LittleCar
      @LittleCar  Місяць тому +1

      Both great ideas, thanks!

  • @mancroft
    @mancroft Місяць тому

    When you get to the Pearly Gates, Saint Peter will say, "We know that you once wrote code in BASIC. You have suffered enough. Skip Purgatory and come straight in".

  • @bozz1954
    @bozz1954 Місяць тому

    I bought a ZX 80 way back then. It lasted 30 min before dying and it took me 6 months to get my money back

  • @mattburland8105
    @mattburland8105 Місяць тому +2

    And to think, this was the original version of EA's PGA Tour game.

  • @soberhippie
    @soberhippie Місяць тому

    Does that primitive basic have substring operations? If so, you could have one long line of outcomes and and array of indexes

    • @LittleCar
      @LittleCar  Місяць тому

      Sort of. See the code review of the Golf 2024 game I linked in the description.

  • @janstrom3482
    @janstrom3482 Місяць тому

    Old computing ❤

  • @ianhaylock7409
    @ianhaylock7409 Місяць тому +1

    Ha, the new code has a bug as it doesn't print the score for the last hole in the table. Guess we have to wait for another 45 years for that to be fixed.

    • @LittleCar
      @LittleCar  Місяць тому

      😂

    • @Penny-mk7fv
      @Penny-mk7fv Місяць тому

      Can’t be fixed, it would break compatibility

  • @nickbeer2658
    @nickbeer2658 Місяць тому

    Is that Hitachi TV a CWP132 by any chance?

    • @LittleCar
      @LittleCar  Місяць тому

      It is. Still works great.

  • @BsktImp
    @BsktImp Місяць тому

    Could you POKE and CALL and thus write machine code routines on the ZX80?

    • @LittleCar
      @LittleCar  Місяць тому

      Well, there's a POKE command, and PEEK is listed in the manual, but not available to use on the keyboard!

  • @TomStorey96
    @TomStorey96 Місяць тому

    I wish I had some early examples of my code to compare how far I've come. But alas. Maybe I can spare myself the cringe afterall 😂

    • @TomStorey96
      @TomStorey96 Місяць тому

      I remember doing silly things like repeating chunks of code because I didn't understand loops properly, although I now know this can be a certain optimisation technique known as "loop unrolling", not that I think it really helped that much at the time. 😊

  • @andygozzo72
    @andygozzo72 Місяць тому

    try using single letter variables, you might then get it in 1k.... also you could've had string arrays in zx81 basic,, you can put a zx81 rom in a zx80 and it'll work as a zx81 except you'll still get the display blanking, thats down to the display hardware, unfortunately,

    • @LittleCar
      @LittleCar  Місяць тому

      I wanted to try to restrict myself to the ZX80 ROM as a bit of a challenge. I originally hoped to make it 1K, but it ended up at least over 3K, so the variable name trick wouldn't have helped.

    • @andygozzo72
      @andygozzo72 Місяць тому

      @@LittleCar the zx80 used to have a 3k rampack, before the 16k one came out, wonder if it'd work with one of those, they're as rare as honest politicians, now, but may be possible to set an emulator to 4k (this pack added 3k on, making 4k total, not disable the internal ram like the 16k and most others did)

    • @LittleCar
      @LittleCar  Місяць тому

      Maybe, but typing that program in on a real machine would do my head in.

    • @andygozzo72
      @andygozzo72 Місяць тому

      @@LittleCar hehe, people did back then😉 i never had a zx80 when 'current' but did start with a zx81 ..

  • @chrispenn715
    @chrispenn715 2 дні тому

    Anybody else progressed from a ZX to a Dragon 32? (Like I did) 😂

  • @craiggilchrist4223
    @craiggilchrist4223 Місяць тому

    Upload it to the Internet Archive.

    • @LittleCar
      @LittleCar  Місяць тому

      They don't want my rubbish!

  • @kwikbit
    @kwikbit Місяць тому

    Can the RND fn not also give you a 0 🤔? 🤓

    • @LittleCar
      @LittleCar  Місяць тому

      I remember PI/PI and PI-PI on the ZX81 used less bytes than 1 and 0 for variables.

  • @pdsnpsnldlqnop3330
    @pdsnpsnldlqnop3330 Місяць тому +4

    The use of variables that are not single letter is not period correct. My inner 11 year old objects to the inefficient use of memory. Besides, you should have been writing it in machine code with just one REM statement. Everyone prefers entering hex code from a magazine, don't they?
    Imagine kids doing it now. They would get ChatGPT to write the code, they would have jQuery and a trendy Javascript framework on the front end, with gibberish cribbed from Stack Overflow. On the backend they would need to load another object oriented framework, to store the data in Firebase and using a constellation of AWS nano services to make it work in the cloud.

    • @LittleCar
      @LittleCar  Місяць тому +1

      Gotta use I as a variable everywhere.

    • @pdsnpsnldlqnop3330
      @pdsnpsnldlqnop3330 Місяць тому

      @@LittleCar I was also impressed by your golf knowledge, in period the game was not as big as today. I would not have had a clue and nobody aged 11 played in my world.
      One topic that does deserve a video is that BASIC and the PC was a step backwards.
      Microsoft was BASIC not that we realised at the time. It comes with concepts such as line numbers, and, when I learned real code, I had difficulty unlearning some of these things.
      This is how BASIC set the world back.
      The PC was a disappointment to me, coming from a BBC Master, I felt 'is there all there is?'
      Everything had been worked out in UNIX and that is what we really have today, but the PC undid it all, to make things like networking need to be reinvented. Yes I thought MS Word was great and there was so much coming out, but, on reflection, it set us all back.
      I think that a video along the lines of what would have happened if we had not have gone down the BASIC/MS-DOS path would be great.

  • @ajax700
    @ajax700 Місяць тому +1

    Why stopped working as programmer?
    Best wishes.

    • @LittleCar
      @LittleCar  Місяць тому +1

      I wanted a change. Making YT videos is a new challenge.

    • @Penny-mk7fv
      @Penny-mk7fv Місяць тому

      IMO the biggest problem with the profession is you have to wrap your head around either the stupidest code or genius level code that cannot be understood or debugged… Google is good at producing both types of code.

  • @baltasarq
    @baltasarq Місяць тому

    I grew up with a Spanish ZX Spectrum 128k. It was a little bit more powerful than the ZX80. About the problem with the if chain, which you mention you would convert it to an array of strings, you can make something up with subroutines. GOSUB is able to jump to the contents of a variable, so you could do something like:
    70 GOSUB 5000 + (SHOT*10)
    5010 PRINT "IS x": RETURN
    5010 PRINT "IS y": RETURN
    5010 PRINT "IS z": RETURN

    • @LittleCar
      @LittleCar  Місяць тому

      Thanks for the example. I still think a string array would be more elegant, and this would have worked on something like a Commodore 64, but even Spectrum 128K BASIC didn't allow multiple statements per line (to my recollection).

    • @baltasarq
      @baltasarq Місяць тому

      @@LittleCar Yep, a string array would be more elegant, and you could write something like that with a Speccy 16k (not sure about the ZX81).
      About multiple statements per line, you can use them for sure! Just separate them with a colon, i.e.:
      10 let x = 0: let y = 0: let z = 0: if y > z then goto 10

    • @LittleCar
      @LittleCar  Місяць тому +1

      Really? It's been too long since I used my Spectrum 128 (sadly sold many moons ago).

    • @baltasarq
      @baltasarq Місяць тому

      @@LittleCar Absolutely!!
      (Did you really have the soul to sell your speccy?? 😪

  • @HansBezemer
    @HansBezemer Місяць тому

    Made a structured version of the original in uBasic/4tH:
    Do
    Proc _Golf
    Input "AGAIN? (Y=1, N=0) "; a
    While a
    Loop
    End
    _Golf
    Local (3)
    For a@ = 1 To 5
    Print
    Next
    Print "GOLF"
    Print "****"
    Let c@ = 0
    For b@ = 1 To 9
    c@ = FUNC(_Play (b@, c@))
    Next
    Print "YOU HAVE FINISHED WITH A SCORE OF "; c@
    If c@ < 10 Then Print "SEE YOU AT GLENEAGLES"
    If c@ > 20 Then Print "SELL YOUR CLUBS"
    If (c@>9) * (c@