6 lines
126 B
Python
6 lines
126 B
Python
|
string = "this is a test"
|
||
|
replaced = string.replace(' ', '-')
|
||
|
print(replaced)
|
||
|
|
||
|
string2 = "hello, world"[-7::-1]
|
||
|
print(string2)
|