Given a rectangular matrix of characters, add a border of asterisks(*
) to it.
Example
For
picture = ["abc",
"ded"]
the output should be
addBorder(picture) = ["*****",
"*abc*",
"*ded*",
"*****"]
Code
function addBorder(picture) {
}
'알고리즘(CF)' 카테고리의 다른 글
17. arrayChange (1) | 2017.06.17 |
---|---|
16. areSimilar (1) | 2017.06.17 |
14. alternatingSums (1) | 2017.06.17 |
13. reverseParentheses (1) | 2017.06.17 |
12. sortByHeight (1) | 2017.06.08 |