Question: This is to be done using c++ and must meet all the program requirements in order to be considered fully functional. E.1. Question 1: Credit

This is to be done using c++ and must meet all theprogram requirements in order to be considered fully functional. E.1. Question 1:Credit Card Validation (60 Marks) Background Information: Have you ever wondered howyour browser knows if your credit card is valid or not beforeyou even click "proceed with purchase"? Credit card numbers actually follow certainThis is to be done using c++ and must meet all the program requirements in order to be considered fully functional.

E.1. Question 1: Credit Card Validation (60 Marks) Background Information: Have you ever wondered how your browser knows if your credit card is valid or not before you even click "proceed with purchase"? Credit card numbers actually follow certain patterns, here's how it works for simple programs using your only browser: A credit card number must have between 13 and 16 digits and each card-type starts with a certain number 4 for Visa Cards 5 for Master Cards 37 for American Express Cards 6 for Discovery Cards. In 1954, Hans Luhn of IBM proposed an algorithm for validating credit card numbers. The algorithm is useful to determine whether a card number is entered correctly or whether a credit card is scanned correctly by a scanner. All credit card numbers are generated following this validity check, commonly known as the "Luhn check" or the "Mod 10 check". This check can be described as using the following arithmetic steps: For this example, let's consider the card number: 4388576018402626 l. Double every second digit from right to left. If doubling of a digit results in a two-digit number, add up the two digits to get a single-digit number. For our example card we have: 2 2- 4 2 2 4 4* 2 8 Etc... 1 2 2 4388576018402626 6 2 12 (1 2 3) 5 2 10 (1 0 1) 8 16 (1 6 70 4 2 38

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!