Data commit
This commit is contained in:
parent
7387c8f97b
commit
cb5bb5e222
199093 changed files with 3378972 additions and 0 deletions
2
Task/Enumerations/Fantom/enumerations-1.fantom
Normal file
2
Task/Enumerations/Fantom/enumerations-1.fantom
Normal file
|
|
@ -0,0 +1,2 @@
|
|||
// create an enumeration with named constants
|
||||
enum class Fruits { apple, banana, orange }
|
||||
7
Task/Enumerations/Fantom/enumerations-2.fantom
Normal file
7
Task/Enumerations/Fantom/enumerations-2.fantom
Normal file
|
|
@ -0,0 +1,7 @@
|
|||
// create an enumeration with explicit values
|
||||
enum class Fruits_
|
||||
{
|
||||
apple (1), banana (2), orange (3)
|
||||
const Int value
|
||||
private new make (Int value) { this.value = value }
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue