Algorithm Optimisation Championship. - page 2

 
Dmitry Fedoseev:

For the championship, the class will have to be placed in a library. Make one function in the library, which will be called from outside, this function will do everything: create an instance of the class, set all parameters passed to the function, etc.

The function name is standard for all. Everyone has their own library file names.

The checker has a script. Checker changes the name of the imported library, compiles, executes.

Should be even simpler, no classes in the executing script. Only imported functions with a call from the *.ex5 library with a standard name, in the library, the participant writes the standard call interface, and is free to do whatever he wants inside. This makes it easier to check both the checkers and the spectators, you only need to change the library file and do not need to recompile every time.
 
Реter Konow:
Do you think you can do without OOP in solving the problem set in the championship? I'm used to solving everything using my own method. (Well, I don't like OOP.) :)
I'm sure you can, but it would be interesting to know your opinion.
 
Реter Konow:
Do you think you can do without OOP in solving the problem set at the championship? I'm used to solving everything by my own method. (Well, I'm not into OOP.) :)

You can. You have to provide a compiled library with one function (with some given name). Whatever else you do and how you do it in that library is up to you (functions or OOP).

Except that the investigated function will be in an object, but that shouldn't be a problem, it's an OOP minimum. Although, it seems that now in mql there are pointers to functions, but I haven't look into it. It's up to Andrei to decide.

 
Реter Konow:
I'm sure you can, but I'd be interested to know your opinion.
You can. That's why I think it's necessary to make do with imported functions only. This is the necessary minimum of practical skills for participation. And in the library of the algorithm you can use both OOP and non-OOP, whichever way you want and to whomever is more convenient.
 
Dmitry Fedoseev:

You can. You must provide a compiled library with one function (with some given name). Whatever else you do and how you do it in that library is up to you (functions or OOP).

Except that the investigated function will be in an object, but that shouldn't be a problem, it's an OOP minimum. Although, it seems that now in mql there are pointers to functions, but I haven't look into it. It's up to Andrei to decide.

Pointers to functions... I'll read the documentation. All I need to know is the essence of the task at hand. If OOP is not necessary, I'll solve it with my own method. Thank you.
 
Where in the help about function pointers, who knows?
 

I'll try to show you an example tomorrow. I am not in a position to write anything in the code today.

Suggest for discussion, in the end it is necessary to come to a common simple solution - connecting the optimization algorithm should not cause problems to anyone.

 
Andrey Dik:
It should be even simpler, without classes in the executing script. Only imported functions with a call from the *.ex5 library with a standard name, in the library, the user writes the standard call interface, and is free to do whatever he/she wants inside. This makes it easier to check both the checkers and the spectators, you just need to change the library file and do not need to recompile every time.

How do you give a function to a member? Then maybe he has to import the function from some library in his library. For me, it's easier with a class. The member has a parameter in the function:

CFF * aff

The use of it is as easy as possible:

aff.value(...)

It's much easier to import and there's no need to bother with unnecessary files.

 
Andrey Dik:
You can. That is why I think it is necessary to make do with imported functions only. This is the necessary minimum of practical skills for participation. And in the library of the algorithm, you can use both OOP and non-OOP, whichever way you like and to whomever is more convenient.
I am familiar with importing functions. It is familiar and clear. But I haven't made any libraries in mql. Only the dll. But I think it is probably easier. Anyway, I'm starting to prepare.
 
Dmitry Fedoseev:

How do you give a function to a member? Then maybe he has to import the function from some library in his library. For me, it's easier with a class. The member has a parameter in the function:

CFF * aff

The use of it is as easy as possible:

aff.value(...)

It's much easier to import and don't bother with unnecessary files.

The *.ex library of the member should be essentially a unified way to refer to its algorithm. The algorithm can be either embroidered into the standard library, or the algorithm can be called from the library using own functions.

And which function to give to the participant? The participant will give it or pass something to him? Play on words, I don't quite get you there.

Reason: