File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11# Личный проект «Кекстаграм»
22
33* Студент: [ Неопознанный енот] ( https://up.htmlacademy.ru/javascript-individual/2/user/1571355 ) .
4- * Наставник: [ Дмитрий Атаманов] .
4+ * Наставник: [ Дмитрий Атаманов] ( https://htmlacademy.ru/profile/atamanov_dmitriy ) .
55
66---
77
Original file line number Diff line number Diff line change @@ -233,6 +233,6 @@ <h2 class="success__title">Изображение успешно загруже
233233 < h2 class ="data-error__title "> Не удалось загрузить данные</ h2 >
234234 </ section >
235235 </ template >
236-
236+ < script src =" js/functions.js " > </ script >
237237</ body >
238238</ html >
Original file line number Diff line number Diff line change 1+ //Функция для проверки длины строки.
2+ const checkStringLength = ( string = '' , maxSimbols = 1 ) => string . length <= maxSimbols ;
3+ window . checkStringLength = checkStringLength ;
4+
5+ //Функция для проверки, является ли строка палиндромом.
6+
7+ const isPalindrome = ( string ) => {
8+ const normalizedString = string . replaceAll ( ' ' , '' ) . toLowerCase ( ) ;
9+ return normalizedString === normalizedString . split ( '' ) . reverse ( ) . join ( '' ) ;
10+ } ;
11+ window . isPalindrome = isPalindrome ;
You can’t perform that action at this time.
0 commit comments