trim method java code example
Example: Java string trim() method
// example on java String trim() method
public class StringTrimJava
{
public static void main(String[] args)
{
String str = " welcome to helloworld java! ";
System.out.println(str);
System.out.println(str.trim());
}
}