Files
highground-fork/string/docs/char_at.md

509 B

string_CharAt

Get character at index in string.

Arguments

  • str (string): string to get character of.
  • index (int): the index in the string you want to get.

Returns

char (string): the character at the specified index in the string.

Raises

  • OutOfBounds: raised if you try accessing a string past its length or at a negative index.

Example

Ground

call !string_CharAt "my string" 3 &char
println $char # "s"

Solstice

puts string_CharAt("my string", 3) // "s"