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

 

Map-1 > mapAB
prev  |  next  |  chance

Modify and return the given map as follows: for this problem the map may or may not contain the "a" and "b" keys. If both keys are present, append their 2 string values together and store the result under the key "ab".

mapAB({"b": "There", "a": "Hi"}) → {"b": "There", "a": "Hi", "ab": "HiThere"}
mapAB({"a": "Hi"}) → {"a": "Hi"}
mapAB({"b": "There"}) → {"b": "There"}

...Save, Compile, Run

public Map<String, String> mapAB(Map<String, String> map) { }


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: 209

Copyright Nick Parlante 2016 - privacy