W=input (' 93 python22)
For x in w: if '0' & lt;=x & lt;='9' : continue the else, w.r eplace (x, ' ')
Print (w)
CodePudding user response:
The replace () method returns a new string object, does not modify the original string,
In [7] : w='93 python22'
In [8], w.r eplace (' p ', ')
The Out [8] : '93 ython22'
In [9] : w
The Out [9] : '93 python22'
CodePudding user response:
W='93 python22'
For x in w:
If '0' & lt;=x & lt; :='9'
The continue
The else:
W=w.r eplace (x, ' ')
Print (w)
CodePudding user response:
String is a constant cannot be modified
CodePudding user response:
The