Skip to main content
2 of 6
added 256 characters in body
12Me21
  • 6.8k
  • 1
  • 23
  • 40

#SmileBASIC, 12 bytes#

?S$[EXP(22)] 

Error message (8 or 9 bytes):

Overflow 

Must be run from the console, otherwise it outputs a line number. Normally errors are formatted like {error} in {slot}:{line}({function}), but this error isn't caused by a function and doesn't have a line number so only the error name is shown.

EXP(x) returns e^x, and e^22 is 584912846.1315918. This is outside the 32 bit signed integer range of -2147483648 to 2147483647. Using this value to access a character in the string S$ converts it to an integer, causing an overflow error.

12Me21
  • 6.8k
  • 1
  • 23
  • 40