Write a c program that reads a credit card number from the user. The c program will display:
Valid: if the credit card is valid
Invalid: if the credit card is invalid
The program will also display the type of the credit card according to the starting digit
(1st digit from left to right). The credit card number must start with:
3 for American Express
4 for Visa
5 for MasterCard
6 for Discover Card
The total number of digits of a credit card number must be between 13 to 16 digits. In addition, your program should validate credit card numbers according to Luhn Rule that is basically can be described as follows (as an illustration, the rules will be applied to the credit card number 4388576018402626):
Numbers and figures are an essential part of our world, necessary for almost everything we do every day. As important…
APPROVED BY CLIENTS
"assignmentexpert.com" is professional group of people in Math subjects! They did assignments in very high level of mathematical modelling in the best quality. Thanks a lot
Comments
Leave a comment