Title: Alternative Solution with List (quite similar to Dictionary) · Issue #57 · realpython/python-basics-exercises · GitHub
Open Graph Title: Alternative Solution with List (quite similar to Dictionary) · Issue #57 · realpython/python-basics-exercises
X Title: Alternative Solution with List (quite similar to Dictionary) · Issue #57 · realpython/python-basics-exercises
Description: Quite short with two nested for loops: cat_count = 100 cats = [False for i in range(cat_count)] for step in range(0, cat_count): for selected_cat_index in range(step, cat_count,step + 1 ): cats[selected_cat_index] = not cats[selected_cat...
Open Graph Description: Quite short with two nested for loops: cat_count = 100 cats = [False for i in range(cat_count)] for step in range(0, cat_count): for selected_cat_index in range(step, cat_count,step + 1 ): cats[sel...
X Description: Quite short with two nested for loops: cat_count = 100 cats = [False for i in range(cat_count)] for step in range(0, cat_count): for selected_cat_index in range(step, cat_count,step + 1 ): cats[sel...
Opengraph URL: https://github.com/realpython/python-basics-exercises/issues/57
X: @github
Domain: patch-diff.githubusercontent.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Alternative Solution with List (quite similar to Dictionary)","articleBody":"Quite short with two nested for loops:\r\n\r\n```\r\ncat_count = 100\r\ncats = [False for i in range(cat_count)]\r\n\r\n\r\n\r\nfor step in range(0, cat_count):\r\n for selected_cat_index in range(step, cat_count,step + 1 ):\r\n cats[selected_cat_index] = not cats[selected_cat_index]\r\n \r\n\r\nfor i in range(cat_count):\r\n if cats[i]:\r\n print(f\"Cat {i+1}: {cats[i]}\")\r\n```\r\n","author":{"url":"https://github.com/Fahrenberg","@type":"Person","name":"Fahrenberg"},"datePublished":"2021-10-14T13:36:01.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":0},"url":"https://github.com/57/python-basics-exercises/issues/57"}
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:ca19ccd0-f315-85a7-ef5c-28894959d7f5 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | A166:2AB24:C3DC12:107233C:697048EB |
| html-safe-nonce | acce688a3c60c0d2aab1a463ca2123a18db654dcc952f10609308c8dd2f86899 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJBMTY2OjJBQjI0OkMzREMxMjoxMDcyMzNDOjY5NzA0OEVCIiwidmlzaXRvcl9pZCI6Ijc1NTUyODI2NTQ0MDQyOTg5ODciLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | ea77809ac1842624367c32dadadeed2375642fcbc48af932312aa368c3672a8a |
| hovercard-subject-tag | issue:1026410344 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/realpython/python-basics-exercises/57/issue_layout |
| twitter:image | https://opengraph.githubassets.com/cdd689599815f558c276975bb71808a71bb6335c44d32e902614541497d0bf77/realpython/python-basics-exercises/issues/57 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/cdd689599815f558c276975bb71808a71bb6335c44d32e902614541497d0bf77/realpython/python-basics-exercises/issues/57 |
| og:image:alt | Quite short with two nested for loops: cat_count = 100 cats = [False for i in range(cat_count)] for step in range(0, cat_count): for selected_cat_index in range(step, cat_count,step + 1 ): cats[sel... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | Fahrenberg |
| hostname | github.com |
| expected-hostname | github.com |
| None | 9920a62ba22d06470388e2904804fb7e5ec51c9e35f81784e9191394c74b2bd2 |
| turbo-cache-control | no-preview |
| go-import | github.com/realpython/python-basics-exercises git https://github.com/realpython/python-basics-exercises.git |
| octolytics-dimension-user_id | 5448020 |
| octolytics-dimension-user_login | realpython |
| octolytics-dimension-repository_id | 128671950 |
| octolytics-dimension-repository_nwo | realpython/python-basics-exercises |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 128671950 |
| octolytics-dimension-repository_network_root_nwo | realpython/python-basics-exercises |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | f643964067a552f02067066d6a910b2f90a5721f |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width