//+------------------------------------------------------------------+ //| Ben.mq5 | //| Copyright 2026, Niquel Mendoza. | //| https://www.mql5.com/ | //+------------------------------------------------------------------+ #property copyright "Copyright 2026, Niquel Mendoza." #property link "https://www.mql5.com/" #property version "1.00" #property strict //+------------------------------------------------------------------+ //| | //+------------------------------------------------------------------+ #include "..\\Main.mqh" //+------------------------------------------------------------------+ //| Script program start function | //+------------------------------------------------------------------+ void OnStart() { //--- const string values[3] { "PERIOD_M10", "PERIOD_M5", "PERIOD_MN1" }; ulong a = GetMicrosecondCount(); for(int i = 0; i < 10000; i++) { const int r = MathRand() % 3; CEnumReg::GetValue(values[r], PERIOD_CURRENT); } ulong b = GetMicrosecondCount() - a; Print("Time: ", b); ///-- /* 2026.06.28 13:17:41.189 Ben (EURUSD,H1) Time: 395 2026.06.28 13:17:41.533 Ben (EURUSD,H1) Time: 399 2026.06.28 13:17:41.887 Ben (EURUSD,H1) Time: 402 2026.06.28 13:17:42.233 Ben (EURUSD,H1) Time: 386 */ } //+------------------------------------------------------------------+