Avatar
omochimetaru 11/7/2017 9:52 AM
↑最近のスレ
9:52 AM
protocol だとユーザが追加した値が入れられちゃいますね あ、abstract class でもその点がダメだな
9:52 AM
- Now you can define a “dependent type”, for example ModuloInteger<P>, where P is the integer value that defines the type. - Like this, you’ll have: —> MI<2>: {0, 1}, where 1 + 1 = 0. —> MI<3>: {0, 1, 2}, where 1 + 1 = 2, and 2 • 2 = 1