-
[Swift] ๋ฐฑ์ค 2941 ํฌ๋ก์ํฐ์ ์ํ๋ฒณ (String)๐ป Algorithm/Swift 2023. 1. 31. 22:37
๐ ํ์ด
๐ฌ Code
import Foundation let alpha = ["c=", "c-", "dz=", "d-", "lj", "nj", "s=", "z="] var word = readLine()! for i in alpha { word = word.replacingOccurrences(of: i, with: "*") } print(word.count)
'๐ป Algorithm > Swift' ์นดํ ๊ณ ๋ฆฌ์ ๋ค๋ฅธ ๊ธ
[Swift] ๋ฐฑ์ค 1260 DFS์ BFS (Graph Traversal) (0) 2023.01.31 [Swift] ๋ฐฑ์ค 14490 ๋ฐฑ๋์ด (์ต๋๊ณต์ฝ์ GCM ๋ฌธ์ ) (0) 2023.01.31 [Swift] ๋ฐฑ์ค 1427 ์ํธ์ธ์ฌ์ด๋ (String) (0) 2023.01.31 [Swift] ๋ฐฑ์ค 4659 ๋น๋ฐ๋ฒํธ ๋ฐ์ํ๊ธฐ (String) (0) 2023.01.31 [Swift] ๋ฐฑ์ค 1181 ๋จ์ด ์ ๋ ฌ (String) (0) 2023.01.31