Yes we can do.
The code goes like this..

import java.util.*;

class StringDemo{
public static void main(String a[]){
String s[]=new String[5];
String name="";
Scanner...