Skip to content

Xcalc: Utility Functions

Read Stanton edited this page Feb 9, 2021 · 12 revisions

Utility Functions

String

str_contains(str, find)

  • String contains function

  • Type: Function

  • Determines whether str contains substring find

str_char_at(str, i)

  • Type: Function

  • Returns the char (as string) at i in str

str_list(str)

  • Converts str to a list

  • Type: Function

  • Returns str as a list

List

ls_add(list, element)

  • Adds element to list and returns the modified list

  • Type: Function

ls_str(list)

  • Converts list to a string

  • Type: Function

ls_contains(list, value)

  • Returns the index of val in list; 0 otherwise

  • Type: Function

Other

parse_fn(function)

  • Type: Program

  • Stores function into f_(x)

parse_fn2(function, name, var)

  • Type: Program

  • Stores function into function variable with name name and variable var

Clone this wiki locally