Contact: aviboots(AT)netvision.net.il
43,964 questions
57,400 answers
573 users
const arr = [1, 3, 8, 9, 17, 18]; const index = arr.findIndex((e) => e === 8); arr[index] = 100; console.log(arr); /* run: [1, 3, 100, 9, 17, 18] */