
import java.util.Scanner; class initials { String a ; int e ; char f ; int b ; int c ; char d; Scanner sc = new Scanner(System.in);
void main()
{
System.out.println("Please enter your name");
a = sc.nextLine();
b = a.length();
System.out.println("The no of letters are :" + b);
for (c = 0 ; c<=b ; c++)
{
d = a.charAt( c );
if (d==' ')
{
e=e+1;
f = a.charAt(e);
System.out.println("The initials are :" + f);
}
}
}
}
what is wrong in it ????

Please go through the following link:
http://www.roseindia.net/tutorial/java/core/printInitials.html

i dont know that split function ..... so i want to know what is wrong in my coding /......