So I have (finally) completed the Credit Card Checker project, which can be found here
While doing some research for the project, I came cross ChildOfCode.com and found this very clean code (below) for validating credit cards using the Luhn algorithm. My question is, how does he use the
var doubleUp = false; in order to double every other number in the array (as the algorithm specifies)? Thanks in advance!