thanks for help.
public class substring {
public static void main(String args[]) {
System.out.println( "example".substring(2, 4));
}
}
I try to compile this, but error message happen, do u have idea anything I
miss in my code? thanks.
Franco
-----Original Message-----
From: Chris Pratt [mailto:[EMAIL PROTECTED]]
Sent: Thursday, January 03, 2002 2:46 PM
To: [EMAIL PROTECTED]
Subject: Re: substring ( ) question
Well, not that it's really a JSP question, but according to the javadocs
that came with your JDK, the answer is "am". Because the parameters are the
starting index (inclusive) and the ending index (exclusive). So, in your
example, you'd get characters 2 and 3.
(*Chris*)
----- Original Message -----
From: "Miao, Franco CAWS:EX" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Thursday, January 03, 2002 2:02 PM
Subject: [JSP-INTEREST] substring ( ) question
> Hi there,
>
> what is outcome of method substring (2, 4) on string "example"? and why?
>
>
> Thanks,
>
>
>
> Franco
>
>
===========================================================================
> To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff
JSP-INTEREST".
> For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST
DIGEST".
> Some relevant FAQs on JSP/Servlets can be found at:
>
> http://archives.java.sun.com/jsp-interest.html
> http://java.sun.com/products/jsp/faq.html
> http://www.esperanto.org.nz/jsp/jspfaq.jsp
> http://www.jguru.com/faq/index.jsp
> http://www.jspinsider.com
_________________________________________________________
Do You Yahoo!?
Get your free @yahoo.com address at http://mail.yahoo.com
===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff
JSP-INTEREST".
For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST
DIGEST".
Some relevant FAQs on JSP/Servlets can be found at:
http://archives.java.sun.com/jsp-interest.html
http://java.sun.com/products/jsp/faq.html
http://www.esperanto.org.nz/jsp/jspfaq.jsp
http://www.jguru.com/faq/index.jsp
http://www.jspinsider.com
===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST DIGEST".
Some relevant FAQs on JSP/Servlets can be found at:
http://archives.java.sun.com/jsp-interest.html
http://java.sun.com/products/jsp/faq.html
http://www.esperanto.org.nz/jsp/jspfaq.jsp
http://www.jguru.com/faq/index.jsp
http://www.jspinsider.com