public class DelimiterMethod { public static void main(String[] args) { Scanner sc = new Scanner(System.in).useDelimiter(","); System.out.println("Enter some value : "); String value = sc.next(); System.out.println("Enter country name : "+value); sc.close(); } }
No comments:
Post a Comment