Created
June 21, 2021 16:51
-
-
Save LewisGet/e0bbe97a47724cbd45b4fc9e271cd170 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def convert(value, sep): | |
list_value = list(value) | |
big = [chr(i + 65) for i in range(26)] | |
_return_value = list() | |
for index, i in enumerate(list_value): | |
t = i | |
if i in big and index is not 0: | |
t = sep + i.lower() | |
elif i in big and index is 0: | |
t = i.lower() | |
_return_value.append(t) | |
return_value = "".join(_return_value) | |
return return_value |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment