mirror of
https://github.com/TheAlgorithms/Python.git
synced 2025-07-06 18:49:26 +08:00
Misc fixes across multiple algorithms (#6912)
Source: Snyk code quality Add scikit-fuzzy to requirements Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> Co-authored-by: Dhruv Manilawala <dhruvmanila@gmail.com>
This commit is contained in:
@ -55,7 +55,7 @@ def is_palindrome_dict(head):
|
||||
d = {}
|
||||
pos = 0
|
||||
while head:
|
||||
if head.val in d.keys():
|
||||
if head.val in d:
|
||||
d[head.val].append(pos)
|
||||
else:
|
||||
d[head.val] = [pos]
|
||||
|
Reference in New Issue
Block a user