Q30.Reverse a sentence based on words. The ith word from the left in the input sentence is the ith word from the end in the output sentence. Choose all options that accept a sentence as input and print the modified sentence.
Example:
```
sentence = "i know how to code in python"
modified_sentence = "python in code to how know i"
```
Save
Check
Details
Q30
16 Jul 2023
Q30.Reverse a sentence based on words. The ith word from the left in the input sentence is the ith word from the end in the output sentence. Choose all options that accept a sentence as input and print the modified sentence.
Example:
```
sentence = "i know how to code in python"
modified_sentence = "python in code to how know i"
```