Solve problem "To swap the two words" online - Learn Python 3 - Snakify

Problem «To swap the two words» (Easy)


Statement

Given a string consisting of exactly two words separated by a space. Print a new string with the first and second word positions swapped (the second word is printed first).

This task should not use loops and if.


In all the problems input the data using input() and print the result using print().



Saved solutions

Tests

Input Correct answer Result
Hello, world!
world! Hello,
A B
B A
Q WERRTYUIOP
WERRTYUIOP Q
QWERTYUIOP M
M QWERTYUIOP
sadfahsjkldfhasjkdfhaklsjdfhjkl asdlkfhasdjklfhaslkdfjhalskdfgalsdf
asdlkfhasdjklfhaslkdfjhalskdfgalsdf sadfahsjkldfhasjkdfhaklsjdfhjkl