functionchar

The character of a given string str at index i is returned.

Extends from Modelica.Icons.Function (Icon for functions).

Information

Syntax

str2 = char(str, i);

Description

The character of a given string str at index i is returned.

Example

  str2 := char("Hello", 2);
      -> str2 = "e"

Inputs

TypeNameDefaultDescription
Stringstrstring to be considered
Integeriindex of chararcter inside str

Outputs

TypeNameDefaultDescription
Stringstr2substring(str, i, i)result character