Detect redundant enumerate
See original GitHub issueRule request
Thesis
# bad
for _, item in enumerate(items):
...
# good
for item in items:
...
Reasoning
Simplification.
P.S. I’m not making it, have seen it in the wild 🙃
Issue Analytics
- State:
- Created 3 years ago
- Comments:8 (3 by maintainers)
Top Results From Across the Web
How do I find the duplicates in a list and create another list ...
To remove duplicates use set(a) . To print duplicates, something like: a = [1,2,3,2,1,5,6,5,5,5] import collections print([item for item, count in ...
Read more >How To Find Duplicates in a Python List - Intellisoft Training
Method 1: Using the length of a list to identify if it contains duplicate elements. ... Let's write the Python program to check...
Read more >Python : 3 ways to check if there are duplicates in a List
Check for duplicates in a list using Set & by comparing sizes · If size of list & set is equal then it...
Read more >Duplicates in a List Finder - dCode.fr
By listing items, dCode detector counts the number of appearance of each, the list can be sorted to detect the most duplicated ones....
Read more >How to find duplicates from a list in Python - Educative.io
The list ( l ) with duplicate elements is taken to find the duplicates. · An empty list ( l1 ) is taken...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
If this is not taken by anybody, can I take it over?
Yes, my bad!
I was confused by:
This should go to
typed-linter
rule.