File: randomlist.cwl

package info (click to toggle)
texstudio 4.3.1%2Bds-2
  • links: PTS
  • area: main
  • in suites: bookworm
  • size: 74,980 kB
  • sloc: cpp: 102,721; xml: 17,126; ansic: 8,143; sh: 194; javascript: 177; makefile: 28
file content (55 lines) | stat: -rw-r--r-- 1,377 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
# randomlist package
# Matthew Bertucci 10/29/2021 for v1.3

#include:xkeyval

\NewList{list}
\ShowList{list}

\ShiftList{list}{start}{number}

\InsertFirstItem{list}{content}
\InsertLastItem{list}{content}
\InsertItem{list}{index}{content}
\InsertRandomItem{list}{content}
\InsertList{receive list}{index}{insert list}

\ExtractFirstItem{list}{macro}
\ExtractLastItem{list}{macro}
\ExtractItem{list}{index}{macro}
\ExtractRandomItem{list}{macro}
\ExtractList{main list}{start index}{end index}{receive list}

\SetFirstItem{list}{content}
\SetLastItem{list}{content}
\SetItem{list}{index}{content}
\SetRandomItem{list}{content}
\SetList{list}{list of contents}
\ClearList{list}
\CopyList{list1}{list2}

\GetFirstItem{list}{macro}
\GetLastItem{list}{macro}
\GetItem{list}{index}{macro}
\GetRandomItem{list}{macro}
\GetList{read list}{start index}{end index}{written list}

\ForEachFirstItem{list}{macro}{code}
\ForEachLastItem{list}{macro}{code}
\ForEachRandomItem{list}{macro}{code}

\ReadFieldItem{record}{rank}{macro}
\ReadFileList{list}{file}
\ReadFileList[separator]{list}{file}

\RLuniformdeviate{number}{macro}
\RLsetrandomseed{value}

\CountList{list}{macro}

\RandomItemizeList{%<item1%>}{%<item2%>}%<{item3}...%>
\RandomEnumerateList{%<item1%>}{%<item2%>}%<{item3}...%>

\RandomListLoaded#S
\RLAtCatcode#S
\RLfor#S