But if you don’t want the size of the list to reset, use this instead:
for each (item) in (list) {
delete (1 v) of (list)
}
or use this if you want:
set [list V] to (numbers from (1) to (10))
for (i) = (1) to ([length V] of (list)) {
replace item (i) of (list) with []
}
Using lists:
Here’s every single list blocks:
item (1 v) of @list
<@list contains [thing]>
<is @list empty?>
([length V] of @list)
(item (1 v) of @list)
add [thing] to @list
delete (1 v) of @list
for each (item) in @list {
} @loopArrow
(map (() @addInput) over @list)
replace item (1 v) of @list with [test]
(append @list @list @delInput @verticalEllipsis @addInput)
(list [] @delInput@addInput)
(numbers from (1) to (10))
([] in front of @list)
(all but first of @list)
(keep items (<> @addInput) from @list)
insert [] at (1 v) of @list
(combinations @list @list @delInput@verticalEllipsis@addInput)
(reshape [] to (4) (3) @delInput@verticalEllipsis@addInput)
(index of [thing] in @list)
(find first item (<>@addInput) in @list)
(combine @list using (<>@addInput))
“Learning one’s lesson” usually suggests that the lesson is to not do something. I’d recommend you use something else like “I learned how to make lists in this thread.” Also, threads are single posts and their replies, topics are a thread with their first post not being on another thread, while the forum is the thing that has all those threads. Topics have headers and are highlighted on the front page.
I believe what @niki650 means is that the variable watcher’s size doesn’t change. I find this useful fairly often, e.g., for the SHAPES list in the Vee project.
An item with a null text in it is different from deleting an item! A tutorial shouldn’t encourage people to be confused about that; they get confused about it without any help. :~) In particular, people write code like this: