Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

java 1: reverseStringInWord: Please fill the function String reverseStringInWord(String str) to return a string which reverse the input word by word. (Note: the words are

java

1: reverseStringInWord: Please fill the function String reverseStringInWord(String str) to return a string which reverse the input word by word. (Note: the words are separated by one more whitespace.)

Example 1: Input: (I am good); Return: good am I Example 2: Input: (How are you) Return you are How

2: MagicString: Please fill the function boolean magicString(String str) to check if a string str is a magic string. A magic String is the one which can be constructed by repeating the substring of it. (Note: you can assume all the characters are in lowercase).

Example 1: Input: abcabcabc Return: True Example 2: Input: ababc Return False

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

More Books

Students also viewed these Databases questions

Question

=+impact member states and MNEs?

Answered: 1 week ago