Learn How to Work with Numbers and Strings by Implementing the Luhn Algorithm - Step 3

Tell us what’s happening:

I have tried the code multiple times, Can you please help me to solve it

Your code so far

User Editable Region

def main():
card_translation=str.makentrans({‘-’: ‘’, ’ ': ‘’})

User Editable Region


### Your browser information:

User Agent is: <code>Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/124.0.0.0 Safari/537.36</code>

### Challenge Information:
Learn How to Work with Numbers and Strings by Implementing the Luhn Algorithm - Step 3
https://www.freecodecamp.org/learn/scientific-computing-with-python/learn-how-to-work-with-numbers-and-strings-by-implementing-the-luhn-algorithm/step-3

There is a typo in the method name.
It’s" maketrans", not “makentrans”.

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.