title: Converting to upper and lower case in Java
body: <p>I want to convert the first character of a string to Uppercase and the rest of the characters to lowercase. How can I do it?  </p>
  
  <p>Example:</p>
  
  <pre><code>String inputval="ABCb" OR "a123BC_DET" or "aBcd"
  String outputval="Abcb" or "A123bc_det" or "Abcd"
  </code></pre>