Você está perdendo oportunidades de negociação:
- Aplicativos de negociação gratuitos
- 8 000+ sinais para cópia
- Notícias econômicas para análise dos mercados financeiros
Registro
Login
Você concorda com a política do site e com os termos de uso
Se você não tem uma conta, por favor registre-se
Código alternativo:
Código alternativo:
if(index>0 || index>8) retorno (-1);
Talvez se(índice < 0 || ...) ...; ?
A segunda versão do código é realmente melhor ... e mais bonita
--
É verdade ... quando é mais difícil manter um código de tamanho otimizado do que um código borrado.
ou seja, escrever de forma mais ampla às vezes é mais fácil de manter...
--
Em SQL está de cabeça para baixo... otimização de código
colocá-lo em uma única consulta até dói
o que é interessante ...
por exemplo, o código SQL de uma consulta complexa é mais difícil de ler do que algumas consultas SQL sucessivas
e por mais estranho que possa parecer, o desempenho de três consultas simples é frequentemente melhor do que o desempenho de uma consulta complexa (aparentemente otimizada)
A lógica daqueles que escrevem consultas SQL complexas... sofre... só porque...
1 - inconveniente para manter
2-baixo trabalho
--
não se aplique ao seu código
isso é apenas por experiência...
Eis algo que eu gostei muito... Extraído do fio do Igor Kim, seu primeiro código:
... e sua segunda:
Como é isso? Isso me agradou pessoalmente... :))Feito um indicador. Mas quando ZZCount>1 o terminal desliga. Parece que não há erros.
Talvez alguém encontre a causa?
Você também pode ser um homem velho.
Muito obrigado!
Às vezes é necessário classificar os dados na MQL4 sem tocar nos próprios dados. Não há indicadores na MQL4, e também não há estruturas.
Aqui está um exemplo de um roteiro que ordena os dados por diferentes parâmetros através da emulação de ponteiros. Talvez alguém ache útil esta abordagem e a função de classificação.
O resultado do trabalho: