dynCount()
Returns the number of elements with the same pattern in the array.
Synopsis
int dynCount(dyn_anytype x, anytype y);
Parameters
Parameter | Description |
---|---|
x | Array to be examined |
y | Value to be examined |
Return Value
If x not contains y 0, in the event of an error -1.
Errors
A message is issued in the event of missing or incorrect arguments.
Description
Returns the number of elements with the same pattern in the array. The data types of y and x have to be in accordance. For example y may not be a dynamic field!
Example
main()
{
dyn_int d;
int x;
d=makeDynInt(60,30, 80, 30, 55, 30);
x=dynCount(d, 30);
DebugN("number:", x); // returns 3
}
Assignment
Dynamic fields
Availability
CTRL