title: Switch statement many parameters and the same treatment
body: <p>I use switch Case to select function the Variable is entred by serial (Ardiuino) Exemple if i write UP or Up even up the same treatment and the same action is called 
  I did it but i got a longer text it's possible to reduce it 
   The code is above </p>
  
  <pre><code>switch (instruction[0])
      {
       case 'P' :
  
                    switch (instruction[1])
              {
               case 'A' :
                          PA(x,y);
               break ; 
               case 'R' :
                        PR(x,y);
               break ; 
               case 'U' :
                        PU(x,y);
               break ; 
               case 'D' :
                        PD(x,y);
               break ;  
  
              case 'a' :
              PA(x,y);
               break ; 
               case 'r' :
                        PR(x,y);
               break ; 
               case 'u' :
                        PU(x,y);
               break ; 
               case 'd' :
                        PD(x,y);
               break ;   
              }
  
          break;
          case 'p' :
  
                    switch (instruction[1])
              {
               case 'A' :
                          PA(x,y);
               break ; 
               case 'R' :
                        PR(x,y);
               break ; 
               case 'U' :
                        PU(x,y);
               break ; 
               case 'D' :
                        PD(x,y);
               break ;  
  
              case 'a' :
              PA(x,y);
               break ; 
               case 'r' :
                        PR(x,y);
               break ; 
               case 'u' :
                        PU(x,y);
               break ; 
               case 'd' :
                        PD(x,y);
               break ;   
              }              
          break;
  
  
  
  
  
       case 'T' :
          Serial.println("error");
          break;
       case 'A' :
  
              switch(instruction[1])
              {
                case 'A' :
                    AA(x,y,z);
                break;  
                case 'a' :
                  AA(x,y,z);
                break;  
  
              }
          break;
  
        case 'a':     
              switch(instruction[1])
              {
                case 'A' :
                    AA(x,y,z);
                break;  
                case 'a' :
                  AA(x,y,z);
                break;  
  
              }
          break;
  </code></pre>
  
  <p>}</p>