User Tools

Site Tools


4rpl:commands:setlistelementrpn

This is an old revision of the document!


Index

SetListElementRPN

SetListElement(<-value <-list <-index)

Description

Stores a value at the specified index of a list. The previously stored value is overwritten.

If a list is stored in a variable, setting a value in it can be abbreviated to <-value ->list[<-index], which will be executed as <-value <-list <-index SetListelementRPN

Examples

Split("1,2,3,4,5,6" ",") ->list1
Split("1,2,3,4,5,6" ",") ->list2
 
0 ->index
 
"one" <-list1 <-index SetListelementRPN
# does the same as
"one" ->list2 [<-index]
 
<-list1 Trace
<-list2 Trace
 
# OUTPUT:
# [one, 2, 3, 4, 5, 6]
# [one, 2, 3, 4, 5, 6]

Index

4rpl/commands/setlistelementrpn.1610638468.txt.gz · Last modified: 2025/02/14 14:56 (external edit)