charAt (Function)
This function returns the char
value that is present at the given
index position. of the input string.
Syntax
<STRING> str:charAt(<STRING> input.value, <INT> index)
Query Parameters
Name | Description | Default Value | Possible Data Types | Optional | Dynamic |
---|---|---|---|---|---|
input.value | The input string of which the char value at the given position needs to be returned. | STRING | No | Yes | |
index | The variable that specifies the index of the char value that needs to be returned. | INT | No | Yes |
Example 1
charAt("gdn", 1)
In this case, the functiion returns the character that exists at index
- Hence, it returns
S
.