Question: Write a program in C+that reads a word and prints it diagonally. You should read the word Char by Char up to the . (dot)
Write a program in C+that reads a word and prints it diagonally. You should read the word Char by Char up to the . (dot).
The word is preceded by either a character r (diagonal towards the right) or l (diagonal towards the left).
For example:
| Input | Output |
|---|---|
| r Diagonally. | D i a g o n a l l y |
| l Yes. | Y e s |
| b blabla. | Wrong input. |
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
