<๋ฌธ์ >
<๋ด ํ์ด>
ํธ๋ํ์ดํฐ ์๊ณ ๋ฆฌ์ฆ ๋ฌธ์ ํ์ด๋ฅผ ํ๋ฉด์
Array ๊ธฐ๋ฅ๊ณผ joined์ ๋ํด์ ๋ฐฐ์ธ ์ ์์๋ค.
โ๏ธinit(repeating:count:) → ํน์ ๊ฐ์ ๋ฐ๋ณต โ๏ธ
(repeating → ๋ฐ๋ณตํ ๋ฌธ์, ๋ฌธ์์ด, ์ซ์, bool / count → ๋ฐ๋ณตํ ํ์)
โ๏ธjoined( ) → ๋ฐฐ์ด ์ ์์๋ค์ ํ๋๋ก ๋ฌถ์๋ ์ฌ์ฉํ๋ ๋ฉ์๋โ๏ธ
โ๏ธjoined(separator:) → ํน์ ์์๋ฅผ ์ถ๊ฐํ์ฌ ๋ฌถ๋ ๋ฐฉ๋ฒโ๏ธ
728x90
'์๊ณ ๋ฆฌ์ฆ(programmers)' ์นดํ ๊ณ ๋ฆฌ์ ๋ค๋ฅธ ๊ธ
[Swift] ํ๋ก๊ทธ๋๋จธ์ค_x๋งํผ ๊ฐ๊ฒฉ์ด ์๋ n๊ฐ์ ์ซ์ (0) | 2024.03.18 |
---|---|
[Swift] ํ๋ก๊ทธ๋๋จธ์ค_๋๋จธ์ง๊ฐ 1์ด ๋๋ ์ ์ฐพ๊ธฐ (0) | 2024.03.15 |
[Swift] ํ๋ก๊ทธ๋๋จธ์ค_์ฝ์์ ํฉ (0) | 2024.03.14 |
[Swift] ํ๋ก๊ทธ๋๋จธ์ค_ํ๊ท ๊ตฌํ๊ธฐ/ ์๋ฆฟ์ ๋ํ๊ธฐ (0) | 2024.03.13 |
[Swift] ํ๋ก๊ทธ๋๋จธ์ค_์ง์์ ํ์ (0) | 2024.03.12 |