Ask your own question, for FREE!
Computer Science 16 Online
OpenStudy (anonymous):

So how would I be able to check if a String spelled with the first letter moved to the last (like banana -> ananab) is the same as the original word just spelled backwards?

OpenStudy (anonymous):

Which language?

OpenStudy (anonymous):

Java. I can put in the code I have so far if it'd help.

OpenStudy (anonymous):

yes please

OpenStudy (anonymous):

do { for (length = word.length() - 1; length >= 0; length--) { oppWord = oppWord + word.charAt(length); } if () oppWord = ""; System.out.println("Please enter the next word: "); word = keyboard.next(); } while (!word.equals("quit")); System.out.println("All done.");

OpenStudy (anonymous):

Write a function to reverse the word, and another to make a string by moving first letter to last; let me call them Reverse() and MoveFirst(); now it must be simpler to write the body of the do while loop. Can you take it from here?

OpenStudy (anonymous):

in c copy each character to stack and compare each character of string with the elemented popped from stack for starting and ending character write corresponding logic (easy)

OpenStudy (rsmith6559):

Ignore the first letter, and check if the rest of the word is a palindrome.

Can't find your answer? Make a FREE account and ask your own questions, OR help others and earn volunteer hours!

Join our real-time social learning platform and learn together with your friends!
Latest Questions
Breathless: Spooky witch but cute
5 hours ago 3 Replies 0 Medals
Arriyanalol: help
5 hours ago 10 Replies 2 Medals
Arriyanalol: @tinydinoUwU stop trying to find a argument u blad lil boy
1 day ago 5 Replies 4 Medals
Jaded012023: Please tell me what you all think of this song
8 hours ago 6 Replies 1 Medal
Arriyanalol: bro how
7 hours ago 2 Replies 3 Medals
Arriyanalol: cant wait for the new bluey movie in 2027
1 day ago 12 Replies 2 Medals
Can't find your answer? Make a FREE account and ask your own questions, OR help others and earn volunteer hours!

Join our real-time social learning platform and learn together with your friends!