Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Latest commit

 

History

History
History
executable file
·
31 lines (25 loc) · 648 Bytes

File metadata and controls

executable file
·
31 lines (25 loc) · 648 Bytes
Copy raw file
Download raw file
Open symbols panel
Edit and raw actions
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
package string;
import java.util.StringTokenizer;
public class StringTokenizer_ {
/**
* @param args
*/
public static void main(String args[]) {
compare();
}
static void StringToken() {
String s = "I am Geng.X.y she is my girlfriend";
StringTokenizer fenxi = new StringTokenizer(s, " ");
int number = fenxi.countTokens();//
while (fenxi.hasMoreTokens()) {
String str = fenxi.nextToken();
System.out.print(str + " ");
//System.out.println("��ʣ" + fenxi.countTokens() + "������");
}
}
static void compare() {
String s1 = "a";
String s2 = s1 + "b";
System.out.println(s2.equals("ab"));
}
}
Morty Proxy This is a proxified and sanitized view of the page, visit original site.