String Class
String message;
"Good Morning World!"
message = "It's Friday";
int length()
int indexOf(String st)
String substring(int start, int end)
- <name> ==> any string of alphanumeric symbols that begins with a letter
- <statement> ==> <name> = <expression> ;
- <statement> ==> <name> = new <class>(<arguments>);
- <statement> ==> <name>.<method>(<arguments>) | <method>(<arguments>) ;
- <arguments> == possibly empty list of <expression>s separated by commas
- <expression> ==> <string-expression> | <int-expression> | <oth-expression>
- <string-expression> ==> <string-expression> + <string-expression>
- <string-expression> ==> <string>
- <string> ==> " any sequence of characters "
- <string> ==> <name>
11. <method> ==> setText | getText | getInt | setInt |
add | actionPerformed | init
12. <compound-statement> ==> {
list of <statement>s
}
13. <statement> ==> if (<bool-expression>)
<compound-statement>
14. <statement> ==> if (<bool-expression>)
<compound-statement>
else
<compound-statement>
public IntField(int size);
public void setInt(int number);
public int getInt();
public DoubleField(int size);
public void setDouble(double num);
public Double getDouble();
while Loop
double weights[];
weights = new double[50];
double weights[] = new double[50];