Python Forum
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
What does this code?
#1
Hello,


What does is this code doing?

def what(n):
 if n<10:
    return n
 else:
    k = what((n//100)*10 + n%10)
    return (k*10 + (n%100) // 10)
thank you.
Yoriz write May-22-2021, 08:38 PM:
Please post all code, output and errors (in their entirety) between their respective tags. Refer to BBCode help topic on how to post. Use the "Preview Post" button to make sure the code is presented as you expect before hitting the "Post Reply/Thread" button.
Reply


Messages In This Thread
What does this code? - by Elvin - May-22-2021, 08:22 PM
RE: What does this code? - by Gribouillis - May-22-2021, 10:39 PM
RE: What does this code? - by Elvin - May-22-2021, 11:35 PM
RE: What does this code? - by Gribouillis - May-23-2021, 06:29 AM
RE: What does this code? - by naughtyCat - Aug-26-2021, 04:05 PM

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020