Awheeler14 / OOP-Asessment-1-Code

0 stars 0 forks source link

Card Shuffle Review #1

Open KieranBurnett opened 1 year ago

KieranBurnett commented 1 year ago

Name: Kieran Burnett (26338680)

Code Review - Card Shuffle

Documentation / Comments

Commented well throughout the code and all classes, however little sections such as public Card[] deck are left without any comments. Some could be included just to explain the more important lines.

Error Handling

Error handling has been done well especially in the class Program. However, improvement could be made in public void dealCard(int amount) as despite there being an int_amount check in the program class, if the method is ran multiple times by the end user it may end up returning an out of bounds exception if they try to deal more than what is left remaining in the pack of cards. A simple deck.length, like used in a previous method, would solve this issue

Code Suggestions

WangTangLahang commented 1 year ago

Name: Lahang Angdembe Student ID: 26584328

Code Review: An adequate amount of comments have been shown throughout the code, there is also good use of exception handling was demonstrated in the section where multiple cards had to be dealt. Furthermore, there were lots of examples of user interactivity being taken into account in the Shuffle and Program class. Incorrect inputs that could have been entered were also taken into account. On the other hand, there could have been some more exception handling scattered throughout the program to ensure stability, however the one used in the Program class was executed well. The only area in the program where there is a lack of extensive commenting is the class Card, but the rest is nicely done and easy to understand.

Overall, most of the requirements have been met aside from the riffle shuffle and the code is structured in an organised and well-planned manner.