Check out example codes for "init cap java". It will help you in understanding the concepts better.

Code Example 1

String str = "java";
str = str.substring(0, 1).toUpperCase() + str.substring(1);
// str = "Java"

Learn ReactJs, React Native from akashmittal.com