title: Caesar Cipher in Java. Encode, decode an rotate a String
body: <p>
  Hi, I am trying to make a program, which allows the user to encode, decode and rotate a String. For example:</p>
  
  <p>User Input: "Caesar"
  System  Output: "Fdhvdu"</p>
  
  <p>The user may decide how much the word is to be rotated. The program is not finished yet, I just made a method for option V: encode and wanted to know if I made it is appropriate? or if it works completely different way!</p>
  
  <pre><code>public class CaesarsChiffre {
  
      public static void main(String[] args) {
  
          char benutzerBefehl;
          String benutzerText;
          int rotation=0;
  
  
          System.out.println("Caesars Chiffre encode, decode, rotate.");
          System.out.println("Waehlen Sie:");
          System.out.println("V for encode");
          System.out.println("E for decode");
          System.out.println("B for rotation");
          benutzerBefehl=V; //Input.readChar();
          System.out.println("Enter text to encode:");
          benutzerText=Input.readString();
          System.out.println("which rotation do you want?");
          rotation=Input.readInt();
  
          switch (benutzerBefehl){ 
          case V: System.out.println(": Encoded text: "+Caesar.encode(benutzerText,rotation));
              break;
          case E: (": Decoded text: "+Ceasar.decode(benutzerText,rotation));
              break;
          case B: // will be filled
              break;
          default:
              System.out.println("Invalid option..");
          }
  
          public static String Caesar.encode(String original_text, int rot){
  
              String []s= original_text.split(" ");
  
              for(int i=0;i&lt;s.length();i++){
                  Stringbuilder letter=new StringBuilder();
                  letter.append(s.[i]+rot);
              }
  
              return String;
  
          }
  
  
  
  
      }
  
  }
  </code></pre>