Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

288
Visualizações
activate an if/else statement if functions are activated in the right order (javascript)

I solved this myself by creating a variable that changes in each function. This var is set to a letter in function a() and if it is that letter when I click on function c() then it changes into another letter and so on. Lastly I have a if statement that activates if it is the right last letter.

I have a project where I have several functions and I want another function to activate if the first 4 functions is activated in a particular order. (and then I want several else if statements to get different functions to activate for other orders, but that I can figure out myself)

I don't know how to get javascript acknowledge that a chain of functions are activated in the right order. (if that is even possible)

as an example: I have function a(), function b(), function c() and function d().

if they are activated in order acbd I want function s() to activate. and if they are activated in order bdca I want function f() to activate.

about 4 years ago · Juan Pablo Isaza
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda