{"id":21005668,"url":"https://github.com/mmendesas/ude_nodealgorithms","last_synced_at":"2025-06-21T10:05:42.138Z","repository":{"id":42882960,"uuid":"199371860","full_name":"mmendesas/ude_nodealgorithms","owner":"mmendesas","description":":computer: :books: some algorithms exercises solved using nodejs","archived":false,"fork":false,"pushed_at":"2023-01-06T03:27:16.000Z","size":660,"stargazers_count":1,"open_issues_count":10,"forks_count":0,"subscribers_count":0,"default_branch":"master","last_synced_at":"2025-06-21T10:04:54.881Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/mmendesas.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2019-07-29T03:30:50.000Z","updated_at":"2023-03-09T02:11:40.000Z","dependencies_parsed_at":"2023-02-05T05:16:22.136Z","dependency_job_id":null,"html_url":"https://github.com/mmendesas/ude_nodealgorithms","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/mmendesas/ude_nodealgorithms","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mmendesas%2Fude_nodealgorithms","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mmendesas%2Fude_nodealgorithms/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mmendesas%2Fude_nodealgorithms/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mmendesas%2Fude_nodealgorithms/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/mmendesas","download_url":"https://codeload.github.com/mmendesas/ude_nodealgorithms/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mmendesas%2Fude_nodealgorithms/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":261103179,"owners_count":23109928,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-19T08:47:46.092Z","updated_at":"2025-06-21T10:05:37.122Z","avatar_url":"https://github.com/mmendesas.png","language":"JavaScript","readme":"## UDE **Node Algorithms**\n:computer:\nA list of some algorithms solved using nodejs\n\n### Run the tests\n1. At the terminal, run `jest reverse/test.js --watch`\n\n### Debug statements\n\n1. Add a `debugger` statement in your function\n    ```javascript\n    const reverse(str) {\n        debugger; // just write this in the code\n        return str.split('').reverse().join('');\n    }\n    ```\n2. Call the function manually in current file\n    ```js\n    reverse('asdf');\n    ```\n\n3. At the terminal, run `node inspect index.js`\n4. To continue execution of the file, press `c` then `enter`.\n    ```sh\n    debug\u003e cont -\u003e continue until the debugger word\n    ```\n5. To launch a `repl` session, type `repl` then `enter`. \n    ```sh\n    \u003e repl -\u003e enter the debug repl (ctrl + c to exit)\n    \u003e str -\u003e to see str value\n    ```\n\n### Notes\n\n - `common string questions`\n    - what is the most common character in a string?\n    - does string A have the same characters as string B (Is it an anagram)?\n    - does the given string have any repeated characters in it?\n- convert the `string` in a `object` representation\n    - `hello there!` -\u003e \n        ```json\n            {\n                \"H\": 1,\n                \"e\": 3,\n                \"l\": 2,\n                \"o\": 1,\n                \" \": 1,\n                \"T\": 1,\n                \"h\": 1,\n                \"r\": 1,\n                \"!\": 1\n            }\n        ```\n    - transform in an object\n    ```js\n        const string = 'Hello There!';\n        const chars = {};\n        for(let char of string){\n            chars[char] = chars[char] + 1 || 1;\n        }\n    ```\n\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmmendesas%2Fude_nodealgorithms","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmmendesas%2Fude_nodealgorithms","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmmendesas%2Fude_nodealgorithms/lists"}