Results 1 to 2 of 2

Thread: question on "case"

  1. #1

    Thread Starter
    Lively Member
    Join Date
    Feb 2002
    Posts
    103

    question on "case"

    char action;

    how do i make it so that there's an OR in the case? when i do it like the example below it gives me an error.

    switch(action)
    {
    case 'e' || 'E': break;
    }

  2. #2
    The Devil crptcblade's Avatar
    Join Date
    Aug 2000
    Location
    Quetzalshacatenango
    Posts
    9,091
    Try this...
    Code:
    switch(action) 
    { 
        case 'e':
        case 'E':
            break; 
    }
    Laugh, and the world laughs with you. Cry, and you just water down your vodka.


    Take credit, not responsibility

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width