Javascript confusions discuss here

Any type of javascript confusion just ask here it will help both of us to grow…

.splice() method -is skipping a index - delete & .filter() is not working perfectly - any other method to do this?

//try it to see index skipping 

let decimalNumber = [ 0, 1, 2, 1.2, 2.22, 5, 7, 8, 3.54, 5.21, 1.27, 6.3, 0.3, 7.77,];

  for (let key in decimalNumber) {
    let a = decimalNumber[key];
    let b = decimalNumber[key].toFixed(0);

    if (a == b) {
      let c = decimalNumber.indexOf(a);
      decimalNumber.splice(c, 1); //try it to see index skipping 
    }
  }


console.log(decimalNumber);

if i run function twicly using loop it’s working

facing the problem in node.js after making server when i run the code in node js it show this error= “Error: Cannot find module ‘C:\Users\nisha\OneDrive\Desktop\visual.code\Costum’”

write all code of your server