%elem return the number of elements of an array/table/ds array. Is there a BIF which gives the number of elements has values, I have an array with dimensions 999.
If the data is present only in the first two elements, i want to run the loop only twice.
I defined the loop as below,
for i = 1 to %elem(array)
{
}
This runs for 999 times even when the data is only in the first two elements. Please suggest better way to handle this.
thanks, Vinoth
If the data is present only in the first two elements, i want to run the loop only twice.
I defined the loop as below,
for i = 1 to %elem(array)
{
}
This runs for 999 times even when the data is only in the first two elements. Please suggest better way to handle this.
thanks, Vinoth
Comment