fork download
  1. process.stdin.resume();
  2. process.stdin.setEncoding('utf8');
  3.  
  4. // your code goes here
  5.  
  6. function temPar(x){
  7. for (let i =0; i < numeros.length; i++){
  8.  
  9. const numeroDaVez= numeros[i]
  10. const resto = numeroDaVez%2
  11.  
  12. if(resto===0 ){
  13.  
  14. return true
  15.  
  16. }
  17. }
  18. return false
  19.  
  20. }
  21.  
  22. const numeros = [1,5,13,7];
  23.  
  24. console.log(temPar(numeros));
Success #stdin #stdout 0.07s 30116KB
stdin
Standard input is empty
stdout
false