var army= ["Marcos", "DeltaForce", "Seals", "SWAT", "HeadHunters"]; if(army.indexOf("Marcos") !== -1) { console.log("Yes, the value exists!") }else{ console.log("No, the value is absent.") }