Skip to content

Conversation

codebasecodebase
Copy link
Owner

No description provided.

summ2 = digit1 + digit3;
summ3 = digit2 + digit3;

if(digit1 < summ && digit1 < summ2 && digit1 < summ3 && digit2 < summ && digit2 < summ2 && digit2 < summ3 && digit3 < summ && digit3 < summ2 && digit3 < summ3) {

Choose a reason for hiding this comment

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

Избыточное условие. Нужно проверить, чтобы сумма двух сторон была не меньше третьей, а не каждой из трех

var digit1 = Number(prompt('Введите первое число')),
digit2 = Number(prompt('Введите второе число'));

if( digit1 % digit2 == 0) {

Choose a reason for hiding this comment

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

Используйте строгое сравнение


d3 = digit1 / 1073741824;

alert(digit1 + "Байт");

Choose a reason for hiding this comment

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

Нужно было вывести только одну единицу - самую подходяющую для значения


var year = Number(prompt('Введите год'));

if(year % 4 == 0 && year % 100 != 0 || year % 400 == 0){

Choose a reason for hiding this comment

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

Используйте строгие сравнения и отрицания

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