Write a java program to shrink a name.

Write a program that accepts a string as input and converts the first two names into dot-separated initials and print the output. Input string format is ‘fn mn ln’.   Output string format is ‘ln [mn’s 1st character].[fn’s 1st character]’ Input and Output Format: Input consists of a string. The output consists of a String. Refer sample output

Write a java program to Swap Characters.

Write a program to input a String and swap every 2 characters in the string. If size is an odd number then keep the last letter as it is. Print the final swapped string. The return type (String) should return the character swapped string. Input and Output Format: Input consists of a string. The output consists

Write a java program to modify a string.

Write a program to input a person’s name in the format “FirstName LastName” and return the person name in the following format – “LastName, InitialOfFirstName”. Input and Output Format: Input consists of a string that corresponds to a Person’s name. Output consists of a string(person’s name in expected format). Refer sample output for formatting specifications.