Merge pull request 'feat(home): resolucao da questao 5' (#5) from feature/exercicio5 into development

Reviewed-on: #5
This commit is contained in:
Edna Barboza de Lima 2022-10-28 11:59:43 +00:00
commit 836f317355

View File

@ -1,4 +1,20 @@
export function isPrime(value) {
// implementar logica aqui
let prime = true
if(value > 1){
for(let i=2; i < value; i++){
if(value % i === 0){
prime = false
break;
}
}
if(prime === true){
return true
}else{
return false
}
}else{
return false
}
}