hacker rank python problem(string split and join)

STRING SPLIT AND JOIN

def split_and_join(line):
    line = "-".join(line.split(" "))
    return line

Compiler Message
Success
Input (stdin)Download
this is a string
Expected OutputDownload
this-is-a-string

Comments

Popular posts from this blog

Amazon Web Services

Google Code-In mentorship experience :)

Hacker Rank all java and python problem solutions