open all | close all

Index Array From String 字符串索引数组Basic 基础Inputs 投入Outputs 产出

Inputs

投入

Mode

模式

Here you can select how the Array should be structured. Since the values in the Array have to be sorted into consecutive index numbers, you can select here if each numeric value should have its own index (indices) or if two values should be included in one index (Indices Pair).

这里您可以选择应该如何构造 Array。由于 Array 中的值必须按连续的索引号排序,因此您可以在此选择每个数值是否应该有自己的索引(索引) ,或者是否应该在一个索引(索引对)中包含两个值。

String

字符串

Here you can enter the values, separated by commas. For example, if 10, 12, 20-15 is entered in indices mode, an Array with a total of eight entries for the values 10, 12, 20, 21, 22, 23, 24 and 25 will be generated.

在这里,您可以输入以逗号分隔的值。例如,如果在索引模式中输入10、12、20-15,那么将生成一个 Array,其中共有8个值10、12、20、21、22、23、24和25。

You can define coherent number rages by simply entering the start and end number with a minus sign in-between. Another option is to use the Count and Default commands. Count defines the total number of values that will be written in the Array; Default defines the default value that will be entered as often as the defined Count. In a second step you can assign diverging values to individual Array elements by placing the element’s index number in square brackets followed by the value for this index. An Example: "count 5, default 2, 317 will produce an Array with the following entries: "2, 2, 2, 17, 2".

您可以通过简单地输入开始和结束数字之间加上一个减号来定义连贯数。另一个选项是使用 Count 和 Default 命令。Count 定义将在 Array 中写入的值的总数; Default 定义将与定义的 Count 一样经常输入的默认值。在第二个步骤中,您可以通过将元素的索引号放在方括号中,后跟该索引的值,来为单个 Array 元素分配不同的值。例如: “ count 5,default 2,317 will produce An Array with the following entry: “2,2,2,17,2”。

In Indices Pair mode, two values will be included in one Array index. This is necessary because an edge can only be addressed via the indices of the start and end points. The entry 0-1, 0-2 will then, for example, select both edges that run between the points with the index numbers 0 and 1, and 0 and 2. Alternatively, pairs can be written using an underscore: 0_1, 0_2.

在索引对模式下,两个值将包含在一个数组索引中。这是必要的,因为边只能通过开始点和结束点的索引来处理。例如,条目0-1、0-2将选择索引号为0和1、0和2的两个点之间的边。或者,配对可以使用下划线编写: 0 _ 1,0 _ 2。