Pair_... Functions
Pair_Count() & Pair_Count_C()
Syntax:
_Pair_Count(Text_or_Value)
_Pair_Count_C(Text_or_Value, SepChar)
Purpose: Counts the number of "pairs" within a string, where pairs are assumed to be separated by a specific character (default is the Character with ASCII code 250).
Parameters:
Text_or_Value: The string to analyze.
SepChar
(Optional): The character used to separate pairs. If you use a
special character here, you'll need to escape it with a %
.
Pick_Pair() & Pick_Pair_C()
Syntax:
_Pick_Pair(Text_or_Value, nPair)
_Pick_Pair_C(Text_or_Value, nPair, Sep_char)
Purpose: Extracts the nth pair from a string, based on a specified separator.
Parameters:
Text_or_Value: The string containing the pairs.
nPair: The index (position) of the pair to extract.
Sep_char (Optional): The character used to separate pairs
Value_... Functions
Value_Count() & Value_Count_C()
Syntax:
_Value_Count(Text_or_Value)
_Value_Count_C(Text_or_Value, SepChar)
Purpose: Counts the number of individual values within a string, separated by a specified character (default is Character with ASCII code 250).
Parameters:
Text_or_Value: The string to analyze.
SepChar (Optional): The character used to separate values.
Pick_Value() & Pick_Value_C()
Syntax:
_Pick_Value(Text_or_Value, nValue)
_Pick_Value_C(Text_or_Value, nValue, Sep_char)
Purpose: Retrieves the nth value from a string, based on a provided separator.
Parameters
Text_or_Value: The string containing the values.
nValue: The index of the value to retrieve.
Sep_char (Optional): The character used to separate values.
Random Swap Functions
Random_Swap()
Syntax: _Random_Swap(array)
Purpose: Randomly swaps the positions of two elements within an array.
Random_Swap_Times()
Syntax: _Random_Swap_Times(array, nTimes)
Purpose: Performs multiple random swaps within an array to shuffle its elements.
Parameters:
array: The array to shuffle.
nTimes: The number of swaps to perform.
Sorting and Swapping
Sort_Array()
Syntax: _Sort_Array(Array_String_Name, order_type)
Purpose: Sorts an array (provided as a string) using a bubble sort algorithm.
Parameters:
Array_String_Name: Name of the array variable (as a string).
order_type (Optional): "A" for ascending, "D" for descending (default is "A")
Swap()
Syntax: _Swap(array, Position_a, Position_b)
Purpose: Swaps the elements at two specific positions within an array.
Important Notes:
Array Representation: Some of these functions might expect your array data to be in the form of a string.
Escaping Special Characters: If your separators are special characters (e.g., ".", "%"), escape them with a "%" in the relevant functions.