Search:

Type: Posts; User: helloworld922

Search: Search took 0.10 seconds.

  1. Replies
    17
    Views
    10,183

    Re: switch with Enums

    The default block is equivalent to the "else" part of an if-else statement. If the given test is false for all the cases, then the default section will be executed.



    private static enum Days...
  2. Replies
    17
    Views
    10,183

    Re: switch with character

    :P A lot of the code I post is off the top of my head. It takes too much time to open up eclipse and type the same thing when I could just do it here. Yeah, I forgot you don't need the full...
  3. Replies
    17
    Views
    10,183

    Re: switch with character

    public class SomeClass
    {
    public static enum Days {SUNDAY, MONDAY, TUESDAY, WEDNESDAY, THURSDAY, FRIDAY, SATURDAY}

    public static void main(String[] args)
    {
    Days a =...
Results 1 to 3 of 3