def replace
(str
: String
): String
= { val regex
= """(\w{3})\w(\w*)""".
r regex.replaceAllIn(str, "$1#$2")
}
println(replace("op hui mat ego shluha"))
}
b2JqZWN0IE1haW4gZXh0ZW5kcyBBcHAgewogIGRlZiByZXBsYWNlKHN0cjogU3RyaW5nKTogU3RyaW5nID0gewogICAgdmFsIHJlZ2V4ID0gIiIiKFx3ezN9KVx3KFx3KikiIiIucgogICAgcmVnZXgucmVwbGFjZUFsbEluKHN0ciwgIiQxIyQyIikKICB9CiAgcHJpbnRsbihyZXBsYWNlKCJvcCBodWkgbWF0IGVnbyBzaGx1aGEiKSkKfQ==