|
![]() |
#1 |
Registered User
Join Date: Jul 2011
Posts: 49
|
public static void main(String[] args) {
Scanner scan = new Scanner(System.in); String x; System.out.print("Input text -> "); x = scan.nextLine(); while(x.length() < 3 || x.length() >20) { System.out.print("Word length must be between 3 and 20 -> "); x = scan.nextLine(); } System.out.println("Text length: " + x.length()); } Something like this i asume?
__________________
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts. To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts. |
![]() |
![]() |
![]() |
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
Thread Tools | |
Display Modes | Rate This Thread |
|
|