Skip to content

PL Homework №1 - #1

Open
Egor-Silinskiy wants to merge 3 commits into
mainfrom
dev
Open

Egor-Silinskiy wants to merge 3 commits into
mainfrom
dev

Conversation

@Egor-Silinskiy

Copy link
Copy Markdown
Owner

ПЛ на первую домашнюю работу. Куда я смотрел, когда отправлял на проверку ссылку на свой репозиторий - не знаю...

@ArturNurtdinov ArturNurtdinov 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.

Очень хороший код, молодец!

Comment thread src/main/java/Car.java
Comment on lines +8 to +13
public String getName() {
return name;
}
public int getSpeed() {
return speed;
}

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Можно чуть сократить здесь код, т.к. две переменные name и speed являются final - можно сделать их публичными, а геттеры убрать - обращаться к ним вместо геттеров можно будет сразу по имени, это безопасно, т.к. они являются final

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