{"id":16874975,"url":"https://github.com/dlsniper/mul","last_synced_at":"2026-05-18T08:31:41.817Z","repository":{"id":141532167,"uuid":"52551164","full_name":"dlsniper/mul","owner":"dlsniper","description":"Question from Slack channel","archived":false,"fork":false,"pushed_at":"2016-02-25T20:19:42.000Z","size":10,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-03-18T23:52:29.168Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/dlsniper.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2016-02-25T19:30:41.000Z","updated_at":"2016-02-25T19:33:53.000Z","dependencies_parsed_at":"2023-05-10T11:08:07.261Z","dependency_job_id":null,"html_url":"https://github.com/dlsniper/mul","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/dlsniper/mul","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dlsniper%2Fmul","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dlsniper%2Fmul/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dlsniper%2Fmul/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dlsniper%2Fmul/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dlsniper","download_url":"https://codeload.github.com/dlsniper/mul/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dlsniper%2Fmul/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":33170828,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-18T05:43:36.989Z","status":"ssl_error","status_checked_at":"2026-05-18T05:43:19.133Z","response_time":71,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"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":"2024-10-13T15:34:47.385Z","updated_at":"2026-05-18T08:31:41.798Z","avatar_url":"https://github.com/dlsniper.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# This is a problem from the Gopher Slack room\n\n\n## Problem:\n\nThe four adjacent digits in the 1000-digit number that have the greatest product \nare 9 × 9 × 8 × 9 = 5832.\n\nThe number is:\n```\n73167176531330624919225119674426574742355349194934\n96983520312774506326239578318016984801869478851843\n85861560789112949495459501737958331952853208805511\n12540698747158523863050715693290963295227443043557\n66896648950445244523161731856403098711121722383113\n62229893423380308135336276614282806444486645238749\n30358907296290491560440772390713810515859307960866\n70172427121883998797908792274921901699720888093776\n65727333001053367881220235421809751254540594752243\n52584907711670556013604839586446706324415722155397\n53697817977846174064955149290862569321978468622482\n83972241375657056057490261407972968652414535100474\n82166370484403199890008895243450658541227588666881\n16427171479924442928230863465674813919123162824586\n17866458359124566529476545682848912883142607690042\n24219022671055626321111109370544217506941658960408\n07198403850962455444362981230987879927244284909188\n84580156166097919133875499200524063689912560717606\n05886116467109405077541002256983155200055935729725\n71636269561882670428252483600823257530420752963450\n```\n\nFind the thirteen adjacent digits in the 1000-digit number that have the greatest \nproduct. What is the value of this product?\n\n## Results\n\n```\nflorin@sniper [09:10:45] [~/golang/src/github.com/dlsniper/mul/mul] [master]\n-\u003e % go test -bench=.                                 \ntesting: warning: no tests to run\nPASS\nBenchmarkMul1-8     2000            684466 ns/op\nBenchmarkMul2-8     5000            457176 ns/op\nBenchmarkMul3-8     5000            212010 ns/op\nBenchmarkMul4-8    10000            150611 ns/op\nBenchmarkMul5-8    10000            153173 ns/op\nBenchmarkMul6-8     3000            976646 ns/op\nok      github.com/dlsniper/mul/mul     10.907s\n```\n\n```\nflorin@sniper [09:09:58] [~/golang/src/github.com/dlsniper/mul/mul] [master *]\n-\u003e % go test -benchmem -test.memprofilerate=1 -bench=.\ntesting: warning: no tests to run\nPASS\nBenchmarkMul1-8     2000            735461 ns/op           17335 B/op          5 allocs/op\nBenchmarkMul2-8     3000            455565 ns/op           24584 B/op          2 allocs/op\nBenchmarkMul3-8     5000            210202 ns/op           16384 B/op          1 allocs/op\nBenchmarkMul4-8    10000            149474 ns/op           16384 B/op          1 allocs/op\nBenchmarkMul5-8    10000            152326 ns/op           16384 B/op          1 allocs/op\nBenchmarkMul6-8     2000           1764112 ns/op           26337 B/op        112 allocs/op\nok      github.com/dlsniper/mul/mul     10.744s\n```\n\n## License\n\nOriginal problem asked by [@mhatch](https://gophers.slack.com/team/mhatch). The code in `mul1` belongs to him.\n\nThe rest is under MIT.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdlsniper%2Fmul","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdlsniper%2Fmul","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdlsniper%2Fmul/lists"}