Computer Science
Which of following is not a valid string operation?
- Slicing
- Concatenation
- Repetition
- Floor
Python String Manipulation
1 Like
Answer
Floor
Reason — In Python, valid string operations include slicing, concatenation, and repetition. However, "floor" is not a valid string operation.
Answered By
1 Like
Related Questions
Which of the following is not a Python legal string operation?
- 'abc' + 'abc'
- 'abc' *3
- 'abc' + 3
- 'abc'.lower()
In Python string, + and * represent which of the following operations?
- Concatenation, Replication
- Addition, Multiplication
- Neither (i) nor (ii)
- Both (i) and (ii)
How many times is the word "Python" printed in the following statement?
s = 'I love Python' for ch in s[3:8]: print('Python')- 11 times
- 8 times
- 3 times
- 5 times
Which of the following is the correct syntax of String Slicing?
- String_name [start : end]
- String_name [start : step]
- String_name [step : end]
- String_name [step : start]