+ 2

How i can do in python?

x=('mango') I want to remove g from mango without use index method how i can do that.

10th Apr 2018, 7:22 AM
Maninder $ingh
Maninder $ingh - avatar
1 ответ
+ 5
The shortest way is to use a replace method. >>> x = 'mango' >>> x.replace('g','') 'mano'
10th Apr 2018, 7:33 AM
strawdog
strawdog - avatar