Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

решение задач 3 модуля #3

Merged
merged 3 commits into from
Feb 1, 2025

Conversation

NastasiaMat
Copy link
Contributor

No description provided.

@jsru-1
Copy link
Contributor

jsru-1 commented Feb 1, 2025

Добавляю преподавателя (@ufocoder) для код-ревью.

@@ -4,5 +4,11 @@
* @returns {*[]} - the new array with uniq values
*/
export function uniq(arr) {
const result = new Set();
Copy link

Choose a reason for hiding this comment

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

Array.from(new Set(arr))

@@ -4,5 +4,13 @@
* @returns {object | undefined} - returns new object or undefined if nothing did't pass
*/
export function invertObj(obj) {
if (obj === undefined) {
Copy link

Choose a reason for hiding this comment

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

if (!obj) { return; }

@jsru-1 jsru-1 merged commit e51200f into js-tasks-ru:master Feb 1, 2025
1 check passed
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.

3 participants