The indefinite article is fine here, although the definite article wouldn't necessarily be wrong. Personally, I prefer the indifinite article.
Let's reword the sentence so it's talking about something other than a GOTO line in a program:
Your paper might have a line with a spelling error.
The play might have a line with a stage direction, such as GRIMACING, or WHILE EXITING LEFT.
A newspaper column might have a line that is comprised of a single word.
The magazine might have a headline printed in red ink.
I think replacing "a line" with "the line" would make those four sentences sound clunky, particularly because they are preceded by "might have".
We could use "the" if we were talking about something that we did have, not something hypothetical that we might have:
Your paper had a lot of problems. There were several misconjugated verbs, and then there was the spelling error on page 3.
In the context of your book:
For example, your code might have a line GOTO 1100.
the word "a" helps the reader not get caught up in particulars. It's a line of code – any line of code. It's a terse way to say something along the lines of:
For example, your code might have a line reading, "GOTO 1100", or, "GOTO 10".
As opposed to something more specific that would allow for the definite article:
We found the bug near the end of that loop, on the line that read GOTO 1100.
Even then, though, the indefinite article would still work:
We found the bug near the end of that loop, on a line that read GOTO 1100.
GOTO *linenumber*
is common. (Ouch! What kind of programming we had back then!) So, it's fine imo becauseGOTO 1100
is not a specific instruction. Any piece of BASIC code could have line 1100.