-
Notifications
You must be signed in to change notification settings - Fork 0
Comments
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Переменная не используется. Можно методы divideBuild и addProducts вызывать отсюда, чтобы выполнение программы было более прозрачным, а не в конструкторе
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Студия подсказывает, что переменную можно перенести в конструктор, где она инициализируется, быть полем класса ей не обязательно
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Переменная инициализируется, но не используется
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Можешь применить в студии автоформатирование (в выбранном файле, сверху вкладка Code - Reformat Code, либо Ctrl+Alt+L), тогда автоматически код выправится
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Можно все эти варианты оставить на последнюю ветку default
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Проверку можно упростить, если использовать (int) Math.floor(pay), и от него брать %10 для вычисления последней цифры и %100 для выяснения, что число между 11 и 19
No description provided.