Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Francis Low] Duke Increments #12

Open
wants to merge 63 commits into
base: master
Choose a base branch
from

Conversation

francislow
Copy link

first pull request

*/

public class Storage {
private static final String filePath = "data/duke.txt";

Choose a reason for hiding this comment

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

constant name should be capitalised

* @param i Index of the task to be returned
* @return Index i of task in list
*/
public Task get(int i) {

Choose a reason for hiding this comment

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

Naming can be improved. What are you trying to get?

public String getStartingMessage(TaskList tasks) {
String message = "Hello! I'm Duke\nWhat can I do for you?\n";
if (tasks.size() == 0) {
message += "You do not have any stored tasks\n";

Choose a reason for hiding this comment

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

avoid using magic variables

import duke.TaskList;

public abstract class Command {
protected String[] parts;

Choose a reason for hiding this comment

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

what this "parts" refer to? can be clearer.

Copy link

@ShuTingY ShuTingY left a comment

Choose a reason for hiding this comment

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

-can implement with more oop
-use SLAP
-avoid using magic values
-naming

KartikeKhandelwal pushed a commit to KartikeKhandelwal/duke that referenced this pull request Sep 27, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants