Discussion of article "MQL5 Cookbook: Implementing an Associative Array or a Dictionary for Quick Data Access" - page 2
You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register
I apologise!
I am just learning about lists and object creation.
When I started testing and digging into your code I found a minor error, but I may be wrong.
When measuring the speed in comparing your library and the standard one, who is faster, you say one thing in the description, but show another on the graph. Didn't you notice it or I'm reading the graph wrong?
P.P. 4.3.
I apologise!
I am just learning about lists and object creation.
When I started testing and digging into your code I found a minor error, but I may be wrong.
When measuring the speed in comparing your library and the standard one, who is faster, you say one thing in the description, but show another on the graph. Didn't you notice it or I'm reading the graph wrong?
P.P. 4.3.
At the beginning I wrote that it is indeed a mistake, but then I looked at the graph more carefully: no, everything is correct. The y-axis shows the time, the longer it is - the slower the item addition works. The chart shows that adding a million items to CArrayObj takes 5 seconds, while adding the same number of items to CDictionary takes 1 second. I.e. specifically in tasks with large sequential addition of elements, the memory reallocation model of CDictionary wins in comparison with the standard reallocation model in CArrayObj, which was required to show.
At the beginning I wrote that this is really a mistake, but then I looked at the graph more carefully: no, everything is correct. The y-axis shows the time, the longer it is, the slower it takes to add an item. The chart shows that adding a million items to CArrayObj takes 5 seconds, while adding the same number of items to CDictionary takes 1 second. I.e. specifically in tasks with large sequential addition of items, the memory reallocation model of CDictionary wins in comparison with the standard reallocation model in CArrayObj, which was required to show.
No, it's still a mistake. but it doesn't matter for me, but for other readers, yes. who will also understand it like me from the beginning. It should be written very precisely because it leads to a distant misconception. ))))
quote: It uses the TEST_ARRAY macro. If it is defined, the test performs operations on CArrayObj, if not - on CDictionary. The first test for adding new elements wins over CDictionary.Its memory reallocation model was better in this particular case:
MUST HAVE: It uses the TEST_ARRAY macro. If it is "NOT" defined, the test performs operations on CArrayObj, if "YES" it performs operations on CDictionary. The first test on adding new elements wins over CDictionary.Its memory reallocation model was better in this particular case:
The whole error is directly in the code from the beginning goes to fill the list through CDictionary , and then if not defined macro TEST_ARRAY goes CArrayObj here is where the error occurred . It's from fatigue of working on one material.
BUT A GREAT AND TIME-CONSUMING ONE. IT HELPED ME A LOT TO UNDERSTAND IN POINTERS AND OBJECT CREATION. IT WAS VERY HARD TO GET INTO IT. AND YOU NEED IT IN A SHORT PERIOD OF TIME......
BmC:
I'VE HAD A LOT OF HELP FIGURING OUT IN POINTERS AND OBJECT CREATION.
В MQL4 и MQL5 нет указателей, есть дескрипторы, это совсем другой компот.
In MQL4 and MQL5 there are no pointers, there are descriptors, this is a completely different compote.
Are you trying to be clever or are you just trying to get a rating. If you do not have time to read the article and what I have written, I ask you not to do that anymore, but write to the creators of MetaQuotes Software Corp. what they have or what should be, but not here to smart people. For those who want it in the future like you: www.mql5.com/ru/docs/basis/types/object_pointers.
You must have a rating only on such stupid statements. Then what are you doing writing nonsense 3000 times? If you have nothing to do, read the MQL reference again. If you need rating on stupid statements so much, then write to the creators of your stupid ideas, they get money for you there.
If you did not understand what I wanted to say with this, then for example, I inform you that you can still write stupid ideas to the creators: " class="linkator">"Object Descriptors"."
Then you give the reason: "Since I am so stupid and I want all my stupid things to become true and reasonable statements, save me "creator".
If I were the "creator", I'd advise you to get a flower of the "seven-flowered flower". But it doesn't matter to you, you've already written three statements. 3093+3=3096. I have helped you now help me not to write here anymore.
I have been on the forum for a long time and your statements I see they are as always stupid and constant. You on the topic write always in snippets and always correct everyone, here such stupid statements. I'm why you are so angry, because I am also the same user beginner who climbs the forum to replenish knowledge and when such a "guru" with a 3000 rating, something writes to him listen. And HE is just a fool who set a goal to score a rating for himself. He does not even think that his statement directs the reader of the branch in the other direction.
I apologise again. If you get caught in my replies again, I will insist on blocking you and you will lose your stupidly scored rating. Especially to prove your stupidity to the moderator is worthless, your answers are always short on the topic and stupid.
It's already September, and this class is not in the standard library:)
By the way, a question about the code of the class itself. What was the point of defining it at the end of the code?
because it is not even used anywhere in the examples...It's already September, and this class is not in the standard library:)
By the way, a question about the code of the class itself. What was the point of defining it at the end of the code?
because it is not even used anywhere in the examples...