id/email
password
forgot password | create account
about | help | code help+videos | done | prefs
CodingBat code practice

 

jebbert@volusia.k12.fl.us > test2021_02_25_HL_passwordMegaScramble
prev  |  next  |  chance

Write a method that repeatedly scrambles a string using the idea from the passwordScramble method described in the SL problem. This time, pass in an array of jumps to make. Scramble the string using jumps[0] as the jump amount. Then take that result and scramble it using jumps[1] as the jump amount. Keep doing this for each element in the 'jumps' array. Return the result. You may use your passwordScramble solution as a helper method (in fact you SHOULD do that).


test2021_02_25_HL_passwordMegaScramble("I_made_this_too_easy!!!", [5, 3, 3, 2, 7, 2]) → "Iysoatd_s!hatm__ee_!oi!"
test2021_02_25_HL_passwordMegaScramble("Yoda_is_a_little_green_Jedi", [7, 5, 3, 5, 7]) → "Ydtniedlioaale_eJsgt___rei_"
test2021_02_25_HL_passwordMegaScramble("abcdefghijklmnopqrstuv", [3, 3]) → "ajsencludmvhqfogpbktir"

...Save, Compile, Run (ctrl-enter)

public String test2021_02_25_HL_passwordMegaScramble(String pswrd, int[] jumps) { }

Editor font size %:
Shorter output


Forget It! -- delete my code for this problem

Progress graphs:
 Your progress graph for this problem
 Random user progress graph for this problem
 Random Epic Progress Graph

Java Help

Misc Code Practice

Difficulty: 290

Copyright Nick Parlante 2017 - privacy