Skip to content

update code formatting, refactored code#1

Open
nazarbodan-indeema wants to merge 1 commit intoDmytroHoretskyi:first_hwfrom
nazarbodan-indeema:first_hw
Open

update code formatting, refactored code#1
nazarbodan-indeema wants to merge 1 commit intoDmytroHoretskyi:first_hwfrom
nazarbodan-indeema:first_hw

Conversation

@nazarbodan-indeema
Copy link
Copy Markdown

No description provided.

}
else{
newWord = newWord + text.toUpperCase()[i]
let newWord = '';
Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

Будь ласка залишайте крапку з комою в кінці кожного рядка, де це можна - це хороша практика.

for (let i in text){

if (text.toUpperCase()[i] === text[i]){
newWord = newWord + text.toLowerCase()[i]
Copy link
Copy Markdown
Author

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.

1 participant