Menu
Java Programming

Java for Loop
A loop is a block of statements that are repeated. A loop may be repeated a fixed number of times, repeat until some condition is met, or can loop indefinitely while the program is running. There are three main loop control structures available in Java: for, do and while. More ...

Reading Files with Java
Without the ability to read files, your application would be severely limited. In this article I show you; how to use the JfileChooser dialog box to select a file, how to display the contents of the file in your applications window, and how to scroll the Window. More ...

Display Text in a Java Program
In computer programming, a letter or digit is called a character and a collection of letters or digits that make a phrase, sentence, or paragraph, is called a string. Example code to display a string in java is provided in this article. More ...

Getting Started as a Java Programmer
One of the reasons for Java's rapid growth is that Sun Microsystems has always makes the Java Software Development Kit (SDK) available at its Web site for free. All you need to develop Java programs is the SDK and a basic ASCII text editor like Windows Notepad. More ...

Comparing Two Text Strings in a Java Program
One task performed frequently in a Java program is to compare two strings. To accomplish this you would use the String object's equals() method. This article provides Java code to compare the text in two strings. More ...

Difference Between JSF, Servlet and JSP
This article provides a brief Overview of JavaServer Faces (JSF), Java ServerPages (JSP), and Java Servlet. More ...

Java if else Control Statement
A computer program is a list of instructions for the computer to follow. The if else statement tells the computer to run on set of instructions based on one result of a test, and a different set of instructions on a different result of the test. More ...

Display Quotation Mark in Text in a Java Program
To define a String in Java, you enclosed it within quotation marks. These quotation marks are not shown when you display the string. More ...

Change the Case of Text in a Java Program
If you compare two characters or two strings, Java will say they are different if all the characters are not the same case. To make a comparison without consideration for case, you can first convert all the characters in a string to lower case using the String objects toLowerCase toUpperCase method. More ...

Locate Text Within Text in a Java Program
In Java a letter or digit is called a character and a collection of letters or digits that make a phrase, sentence, or paragraph, is called a string. Java uses the String object's .indexOf method to locate one string within another. More ...

Display a Line Break in Text in a Java Program
In computer programming, a collection of letters that make a phrase, sentence, or paragraph, is called a string. Within a string there may be special characters that are used to produce things like tabs, backspaces, and carriage returns. A line break is created using the newline special character. More ...

Concatenate Strings in a Java Program
Java uses the concatenate (+) operator to paste two or more strings together. This article provides Java code to concatenate the strings "first text " and "second text". More ...

Java Ternary Operator Control Statement
The ternary operator (?) is often confusing to beginners. The ternary operator is used to assign one of two values to a variable based on a conditional test. More ...

Display Variable's value in Text in a Java Program
Java uses the concatenate operator (+) to paste two or more strings together. However, you can also use the concatenate operator to display the value of a variable with a String. Java will automatically convert the integer values to Strings for display. More ...


Learn more at amazon.com

Custom Search