MQL4 - automated forex trading   /  

Documentation

MQL4 Reference  Array functions  ArrayMinimum

 
Use the opportunities of
MQL5 in MetaTrader 5
Study the new MQL5 language
Study the new MQL5 language.
Reference is already available
int ArrayMinimum( double array[], int count=WHOLE_ARRAY, int start=0)
Searches for the element with minimum value. The function returns position of this minimum element in the array.
Parameters:
array[]   -   The numeric array to search in.
count   -   The amount of elements to search in.
start   -   Initial search index.
Sample:
double num_array[15]={4,1,6,3,9,4,1,6,3,9,4,1,6,3,9};
int    minValueidx=ArrayMinimum(num_array);
Print("Min value = ", num_array[minValueIdx]);