Hello, @trishnapandey0880521, and welcome to the forums.

First of all:

```
for (let i=15; i>=0; i--){
```

That won’t work for several of the numbers. Not all of the credit card numbers have 16 digits. Also you need to perform the doubling and possible subtracting of 9 on every other digit after skipping the last digit. Using the `even-ness`

or `odd-ness`

of the digit’s index in the array to determine which numbers to perform those actions on won’t work either on numbers with an odd number of digits.

You might need to re-consider your approach.

Also, I’d get away from using `var`

. Use `let`

or `const`

. None of your variables require function scope. Block scope is sufficient for all of them.