Skip to Content
Real World XML
book

Real World XML

by Steven Holzner
January 2003
Beginner to intermediate content levelBeginner to intermediate
1200 pages
23h 42m
English
Peachpit Press
Content preview from Real World XML

Creating Strings in Java

You might have noticed that you can add strings together with the + operator in Java, just as you can in JavaScript:

public class ch10_05 
{
    public static void main(String[] args)
    {
        double chargesDue[][] = {{1093.66, 667.19, 45.99, 890.30, 99.06},
                                   {2019.00, 129.99, 19.01, 630.90, 23.17}};

        System.out.println("Customer 4 owes $" + chargesDue[0][4] + " in the Eastern
 branch.");
					System.out.println("Customer 4 owes $" + chargesDue[1][4] + " in the Western
 branch.");
}
}

This works because strings are supported by the built-in ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Inside XML

Inside XML

Steven Holzner
XML Hacks

XML Hacks

Michael Fitzgerald

Publisher Resources

ISBN: 0735712867Purchase book