How i create queue? | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

How i create queue?

can someone please explain how can i create a char queue that with input "hi i am oliviero" give as output "oliviero am i hi"

16th Feb 2017, 11:06 PM
Oliviero 1
Oliviero 1 - avatar
1 Answer
0
Working with chars if you want to change the order of the words doesn't fully match. If want to do that, I would recommend spliting your String "hi i am oliveiro", then making a new array with your splitted parts, and printing them from last to first.
17th Feb 2017, 2:38 AM
Albert Marc
Albert Marc - avatar