0

Input a string as a name and print the initials of the name, using string functions.

For example, Input: Deepak Kumar Verma output: D K V Please, not using scanner class.

19th Oct 2018, 12:10 PM
Adya Srivastava
1 Resposta
+ 1
You can split the string on whitespaces which will result in an array. Then you can loop over the array and save the first letter of each word. Or you can use a regular expression.
19th Oct 2018, 1:43 PM
Willem Roos