Question: BlueJ programming(Java). Has to work when I compile and run it. Please and thanks. Assignment-8 For this assignment, write a program to validate credit card

BlueJ programming(Java). Has to work when I compile and run it. Please and thanks.  BlueJ programming(Java). Has to work when I compile and run it.

Assignment-8 For this assignment, write a program to validate credit card numbers as explained in Programing Exercises 6.31 on page 243 in the book. Refer to section 6.2 on page 236 for a relevant discussion Requirements Create the methods main, sumOdd, sumEven, validLength, validNumber and type with the following properties: main Prompts for a credit card number, reads the number from the keyboard and calls the other methods to produce the required results validLength Checks the length of the number entered and returns true if the number is 13 or 16 digits in length. validNumber Checks the values returned from sumodd and SumEven and returns true if the credit card number is correct, or false otherwise. type Returns the type of the credit card the number represents (visa, discover, etc.) sumEven Sums the digits in even positions according to the algorithm provided in the book. sumOdd Sums the digits in odd positions according to the algorithm provided in the book

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!