This is a free site for programming practice. Complete the code in the browser and submit. Try this example. If your report looks like this, keep on trying until all test cases pass.
For more problems, follow one of the links below.
There are two points.
1) Drill and practice. The problems test a single skill, such as writing a simple loop.
2) Cleaner homework. When a programming assignment passes the test, the classes have the right names, the methods have the right parameters, and the program outputs have the right formats. The student gets feedback that the solution works (at least for the provided test cases), and the grader can focus on style and substance.
Use Firefox or Chrome.
You don’t. The system has no long-term memory. It just runs the tests and displays the report. The report will hang around for a few hours, but don’t count on it.
If your professor asked for it, click on the Download button to get a signed zip file. Follow your professor's instructions on how to submit the report to them (by email, by submitting it into your learning management system, carrier pigeon, whatever).
jarsigner -verify Submission.signed.zip. You should get a message
No. The problems on this site (including the problem statements, code, and arrangement) are copyrighted by Cay Horstmann or John Wiley & Sons, Inc, and you may not publish any of those. We ask nicely that you don't post solutions. It defeats the purpose of practice exercises. And what's the point? It doesn't make you look smart or employable.
If you have suggestions for improvement, please contact the author, Cay Horstmann (firstname.lastname@example.org).