Get started with lists in our Lists article. Once you have a list, you can use list operations to modify it. Find list operations in the Functions Keypad, or type any function directly into the expression list.
| Function | Inputs | Example | Description |
|---|---|---|---|
| repeat | Two equal sized lists | repeat([1,5],[3,2]) |
Repeat each value in the first element according to the values of the corresponding second element. So, in the example, 1 is repeated three times, and 5 is repeated twice. Use the repeat function to create frequency tables. |
| join | Two or more lists | join([1,5],[3,2]) | Combines two or more lists into one list. |
| sort | one list | sort([5,1]) | Sorts the elements from smallest to largest. |
| shuffle | one list | shuffle([2,3,9]) |
Randomizes the elements in your list. When you add the shuffle function to the expression list, the Randomize icon will appear. You can click it to reshuffle your list elements at any time. |
| unique | one list | unique([1,5,5,10]) | Outputs a list of each element that is used in the list and removes any repeats. |
| for | Lists or intervals | (a,b) for a=[1,2], b=[1,2] (sin(c),cos(c)) for \(0 \lt x \le 2\pi\) | Test multiple values for a variable with either a list or an interval. |
Learn More
Please write in with any questions or feedback to support@desmos.com.