DEV Community

Discussion on: python challenge_6

Collapse
 
alvisonhunter profile image
Alvison Hunter Arnuero | Front-End Web Developer
def add_dots(string):
    return ".".join(string)

def remove_dots(string):
    return string.replace(".", "")

print("With Dots: ", add_dots("test"))  # t.e.s.t
print("Without Dots: ", remove_dots("t.e.s.t"))  # test
print("Back to Original: ", remove_dots(add_dots("alvison"))) # alvison
Enter fullscreen mode Exit fullscreen mode
Collapse
 
mahmoudessam profile image
Mahmoud EL-kariouny

Good job pro :)

Collapse
 
alvisonhunter profile image
Alvison Hunter Arnuero | Front-End Web Developer

Thanks, champion!

Thread Thread
 
mahmoudessam profile image
Mahmoud EL-kariouny

Not at all :)