Hi , can any one explain me this code
public class Howcome {
public static void main(String[] args) {
System.out.println(“Bank of America”);
https://www.bankofamerica.com
System.out.println(“Online Banking”);
}

even though https:// BofA lyin as orphan string in between this codes compiles and executes fine..???

Recommended Answers

All 4 Replies

Please post your code in code tags to preserve formatting and to show the real code without there being a hyperlink in the middle of it.

In java you can create a label to use with loops, break & continue statements. See http://www.janeg.ca/scjp/flow/labels.html for an example of how this works. The syntax for creating a label is an identifier, followed by a colon. Then remember that single-line comments in java start with //. So the code you asked about is interpreted as a label ("https:") and then a comment (//www.bankofamerica.com).

commented: very good +3

kramerd: that is so neat. Thanks for making my day! J

Thank you very much for replying... have a great day guys!!

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.