ํํ
fn main() { let t: (i8, bool) = (7, true); println!("t.0: {}", t.0); println!("t.1: {}", t.1); }
This slide should take about 5 minutes.
-
๋ฐฐ์ด๊ณผ ๋ง์ฐฌ๊ฐ์ง๋ก ํํ์ ๊ณ ์ ๊ธธ์ด๋ฅผ ๊ฐ์ต๋๋ค.
-
ํํ์ ์๋ก ๋ค๋ฅธ ํ์ ์ ๊ฐ๋ค์ ํ๋์ ๋ณตํฉ ํ์ ์ผ๋ก ๋ฌถ์ต๋๋ค.
-
ํํ์ ์ํ ๊ฐ์
t.0
,t.1
๊ณผ ๊ฐ์ด ์ธ๋ฑ์ค๋ก ์ ๊ทผํ ์ ์์ต๋๋ค. -
The empty tuple
()
is referred to as the โunit typeโ and signifies absence of a return value, akin tovoid
in other languages.