aboutsummaryrefslogtreecommitdiff
path: root/challenge-096/laurent-rosenfeld/python/ch-1.py
blob: 317f5571759c5a40defbf7c19d8b92cee7855c45 (plain)
1
2
3
4
5
6
7
def reverse_words(in_str):
    words = in_str.split()
    words.reverse()
    return " ".join(words)

input = "    Perl and   Raku are  part of the same family  "
print(reverse_words(input))