O'Reilly logo

Minecraft Mods Programming Absolute Beginner’s Guide by Rogers Cadenhead

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

7. Use Strings to Communicate

In This Chapter

Use strings to store text

Display strings in a program

Include special characters in a string

Paste two strings together

Include variables in a string

Compare two strings

Determine the length of a string

In Minecraft, information often is presented to players as a line of text on the screen. A line of text in a Java program is called a string.

Strings are the simplest and most common means to communicate with users in any program. They are collections of text—letters, numbers, punctuation, and other characters. During this chapter, you learn all about working with strings.

Storing Text in Strings

Strings store text and present it to users. The most basic element of a string is a character. ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required