Files
mql5-skills/skills/mql5/references/docs/34-standardlibrary/1297-standardlibrary-mathematics-stat-mathsubfunctions-statmathsequence.md
T
2026-06-23 21:47:51 +08:00

50 lines
1.0 KiB
Markdown
Raw Blame History

This file contains invisible Unicode characters
This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
# MathSequence
Generates a sequence of values based on the following values: the first element, the last element, the step of the sequence.
Version for working with real values:
```
bool  MathSequence(
   const double  from,       // initial value
   const double  to,         // final value
   const double  step,       // step
   double&       result[]    // array of results
   )
```
Version for working with integer values:
```
bool  MathSequence(
   const int     from,       // initial value
   const int     to,         // final value
   const int     step,       // step
   int&          result[]    // array of results
   )
```
Parameters
from
[in] The first value of the sequence
to
[in] The last value of the sequence
step
[in] The step of the sequence.
result[]
[out] Array to output the sequence.
Return Value
Returns true if successful, otherwise false.