Are you taking CLEP classes? Try clep.ai
| preferred AP College board partner for AP classes
hard Solved by 20 students

String Manipulation With Substring

< Prev
Next >

Consider the following method.

public static String scramble(String word, int howFar)
{
    return word.substring(howFar + 1, word.length()) + 
           word.substring(0, howFar);
}

What value is returned by the call scramble("compiler", 3)?

A

“compiler”

B

“ilercomp”

C

“ilercom”

D

“pilercom”

Hint
Did You Know?
Explain Why
Explain All Answers
Check Answer
Show Correct Answer
Report Question
Mark for review

Question Leaderboard

Rank
User
Correct Count
Attempt Count
Total Time
Score
#1hiboyshello11 0m 00s 100
#2varunrajaram111 0m 00s 100
#3y.seong202711 1m 02s 38
#4bommasam00011 1m 17s 23
#5kazvin.tjakradinata12 1m 14s 16
#6hyeokjinlee092412 1m 28s 2
#7alchemax04311 1m 38s 2
#8lsj0803092212 1m 35s -5
#9angelajxi1101 0m 00s -10
#10michael.2103ll01 0m 00s -10
Items per page:
10
1 – 10 of 22
No comments yet. Be the first to comment!

AI Tutor

How can I help?

APFIVE © 2020.
Email: apfive@apfive.org|Privacy Policy|FAQ