Hacker News new | ask | show | jobs
by max99x 5375 days ago
You might be hitting the fact that QBasic actually requires keywords to be in capitals. The original IDE did the conversion for you, but repl.it doesn't. We should really be more lenient about those. For now, check the existing examples and use your trusty caps lock.
1 comments

The actual QuickBASIC compiler allowed any case for keywords.

The lack of line numbers was a bit confusing too - my first inclination when seeing a BASIC prompt is to type

  10 PRINT "hello"
  20 GOTO 10
Aside from that, it seems to work as expected (at least in the quick tests I tried).
Numeric labels also don't work:

  10: PRINT "hello"
  GOTO 10
This works though:

  label: PRINT "hello"
  GOTO label