YouTip LogoYouTip

Java String Charat

# Java charAt() Method [![Image 3: Java String Class](#)Java String Class](#) * * * The charAt() method is used to return the character at the specified index. The index range is from 0 to length() - 1. ### Syntax public char charAt(int index) ### Parameters * **index** -- The index of the character. ### Return Value Returns the character at the specified index. ### Example ## Example public class Test{public static void main(String args[]){String s = "www."; char result = s.charAt(6); System.out.println(result); }} The output of the above program is: n * * Java String Class](#)
← Css ImportantMatplotlib Bar β†’