A string called str contains whitespaces at the left of the string as given.
Str= “ Python program”
5*2=10
Write the command to delete the spaces.
Answers
Answered by
0
Answer:
String result = str. trim(); The trim() method will remove both leading and trailing whitespace from a string and return the result.
Similar questions
History,
2 months ago
CBSE BOARD XII,
2 months ago
Math,
2 months ago
Science,
5 months ago
Science,
5 months ago
Chemistry,
10 months ago
Hindi,
10 months ago
CBSE BOARD X,
10 months ago