Skip to content

Level 3 completed - #77

Open
hongquan448 wants to merge 23 commits into
nus-cs2113-AY1920S2:masterfrom
hongquan448:master
Open

Level 3 completed#77
hongquan448 wants to merge 23 commits into
nus-cs2113-AY1920S2:masterfrom
hongquan448:master

Conversation

@hongquan448

Copy link
Copy Markdown

All the functions are clumped together for now, next step is level 4 and creating individual

@trishaangelica trishaangelica left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Overall, we found your code easy to read for the most part except for a few places. We hope our comments can help you improve the code further.
All the best for your iP :-)
[Also took part in this review: @jiajuinphoon]

Comment thread src/main/java/Duke.java Outdated
}
break;
case "done":
command = input.next();

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great job so far! Perhaps, this variable "command" could be named better since there is already another variable "command" used? 😄

Comment thread src/main/java/Duke.java Outdated

System.out.println("Hello! I'm Duke\nWhat can I do for you?");

loop: do {

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

loop label is commonly used in C.. maybe you could exit at the case: "bye" instead of having a switch with a do-while loop? 💭

Comment thread src/main/java/Duke.java
Comment on lines +16 to +19
switch(command) {
case "bye":
System.out.println("Bye. Hope to see you again soon!");
break loop;

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

good job on following the coding standard 👍

Comment thread src/main/java/Duke.java Outdated
System.out.println("Nice! I've marked this task as done:");
System.out.println("[Done] " + tasks[i-1]);
break;
default:

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Another possible suggestion is to add comment lines so that it's easier to follow through a block of code 😃

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants