0

what enum means

25th Nov 2016, 11:43 PM
Abdenour Sahel
Abdenour Sahel - avatar
2 Respuestas
+ 3
Enums is a special collection of constants. for example enum Fruits { MANGO, CASHEW, APPLE } it has alot of practical applications. an example is checking the presence of one constant if it's in the group. you can use switch for this. e. g. switch (Fruits) { case MANGO: System.out.println("Mango is a fruit"); }
25th Nov 2016, 11:56 PM
damilare lamidi
damilare lamidi - avatar
0
good
26th Nov 2016, 12:14 AM
Abdenour Sahel
Abdenour Sahel - avatar