{"id":24740408,"url":"https://github.com/derektypist/project-euler-012","last_synced_at":"2026-05-14T20:32:58.918Z","repository":{"id":100100603,"uuid":"483580465","full_name":"derektypist/project-euler-012","owner":"derektypist","description":"The sequence of triangle numbers is generated by adding the natural numbers.  So the 7th triangle number would be 1 + 2 + 3 + 4 + 5 + 6 + 7 = 28.  The first 10 terms would be 1, 3, 6, 10, 15, 21, 28, 36, 45 and 55.  1 has 1 factor, 3 has 2 factors, 6 has 4 factors, 10 has 4 factors, 15 has 4 factors, 21 has 4 factors and 28 has 6 factors.  We can see that 28 is the first triangle number to have over 5 divisors.  Find the value of the first triangle number to have over n divisors.","archived":false,"fork":false,"pushed_at":"2022-04-20T11:31:44.000Z","size":11,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-09-07T21:32:37.501Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://derektypist.github.io/project-euler-012/","language":"HTML","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/derektypist.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,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2022-04-20T08:59:50.000Z","updated_at":"2022-04-20T11:19:50.000Z","dependencies_parsed_at":"2023-05-12T07:30:21.837Z","dependency_job_id":null,"html_url":"https://github.com/derektypist/project-euler-012","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/derektypist/project-euler-012","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/derektypist%2Fproject-euler-012","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/derektypist%2Fproject-euler-012/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/derektypist%2Fproject-euler-012/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/derektypist%2Fproject-euler-012/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/derektypist","download_url":"https://codeload.github.com/derektypist/project-euler-012/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/derektypist%2Fproject-euler-012/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":33042183,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-13T13:14:54.681Z","status":"online","status_checked_at":"2026-05-14T02:00:06.663Z","response_time":57,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":"2025-01-27T23:23:35.303Z","updated_at":"2026-05-14T20:32:58.912Z","avatar_url":"https://github.com/derektypist.png","language":"HTML","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Project Euler 012 - Highly Divisible Triangular Numbers\n\nThe sequence of triangle numbers is generated by adding the natural numbers.  So the 7th triangle number would be `1 + 2 + 3 + 4 + 5 + 6 + 7 = 28`.\n\nThe first ten terms would be:\n\n`1, 3, 6, 10, 15, 21, 28, 36, 45. 55, ...`\n\nLet us list the factors of the first seven triangle numbers:\n\n      1: 1\n      3: 1,3\n      6: 1,2,3,6\n     10: 1,2,5,10\n     15: 1,3,5,15\n     21: 1,3,7,21\n     28: 1,2,4,7,14,28\n\nWe can see that 28 is the first triangle number to have over 5 divisors.\n\nWhat is the value of the first triangle number to have over n divisors (e.g. 500)?  The aim is to answer this question using HTML Forms and JavaScript.\n\nInformation at [Project Euler 012](https://projecteuler.net/problem=12)\n\n## UX\n\n**Getting Started**\n\nEnter a whole number between 1 and 1000 in the input field and click on the Submit Button.  You will see the number you have entered as well as the first triangle number to have over n divisors, unless you have made an invalid input.  For example, if you entered 5, you should get 28 as the first triangle number to have over n divisors.  Click on the Reset Button to clear that information or to start again.\n\n**User Stories**\n\nAs a user, I expect to get an invalid input if I do any of:\n\n* Not enter anything in the input field\n* Entering text that is not a number (e.g. bus)\n* Entering a number less than 1 or greater than 1000\n* Entering a number, but it is not an integer\n\nAs a user, I expect the function `divisibleTriangleNumber(5)` to return a number.\n\nAs a user, I expect the function `divisibleTriangleNumber(5)` to return 28.\n\nAs a user, I expect the function `divisibleTriangleNumber(23)` to return 630.\n\nAs a user, I expect the function `divisibleTriangleNumber(167)` to return 1385280.\n\nAs a user, I expect the function `divisibleTriangleNumber(374)` to return 17907120.\n\nAs a user, I expect the function `divisibleTriangleNumber(500)` to return 76576500.\n\n**Information Architecture**\n\nThe function `divisibleTriangleNumber(n)` returns a number, where `n` is the number of divisors between 1 and 1000.\n\n## Features\n\nAllows the user to enter the number of divisors, as well as getting the first triangle number to have over that number of divisors.  Performs checks to see if the input is valid.  If the input is not valid, an error message is displayed.\n\n## Technologies\n\nUses HTML5, CSS3, JavaScript, Bootstrap 5.1.3 and Google Fonts.\n\n## Testing\n\nEnsure all user stories have been met.\n\n## Deployment\n\nDeployed on [GitHub Pages](https://derektypist.github.io/project-euler-012) at the main branch.\n\n## Credits\n\n### Content\n\nWritten by me.\n\n### Acknowledgements\n\n- [Project Euler](https://projecteuler.net)\n- [FreeCodeCamp](https://www.freecodecamp.org)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fderektypist%2Fproject-euler-012","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fderektypist%2Fproject-euler-012","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fderektypist%2Fproject-euler-012/lists"}