Examples · learn/07-errors · 128 of 339
panic.panics
panic is for bugs: things that should never happen.
tin run examples/learn/07-errors/panic.panics.tin// panic is for bugs: things that should never happen. It stops the program.
fn main() {
let scores = [90, 72, 85]
print(scores[0])
print(scores[3]) // there is no fourth score
}