课程: Learning Java 17
What is Java?
- [Instructor] Java is a commonly-used programming language and it's often the first language beginners learn. When we say programming language, we do mean that it's an actual language, but we use it to talk to a computer. Just like a regular language, it has a vocabulary and a set of grammatical rules so that we can communicate with a computer to complete certain tasks. With the Java programming language, software engineers can create applications on a computer. Think web applications, mobile applications, desktop applications, embedded systems, and more. We call these applications Java applications or Java programs because they're built with the Java programming language. Chances are, you've downloaded a program that requires the JRE, or the Java Runtime Environment. This is what's needed to execute or run Java programs and it's often what you've installed in the past in order to run Java applications on your computer. You may not have thought of them as Java applications back then, but anytime you were asked to install or update Java in order to run the application, they were indeed Java programs. Now, you might be wondering why is the JRE needed? Why can't any machine just interpret my Java code? Well, there are two processes that happen when we create Java programs. First, we write the code in Java. Then, when we want to test the code, we compile it into Java by code. This is what we mean when we say we build or compile Java programs. It's essentially transforming it into another format so that it can be executed. In the case of Java, we transform it or compile it into Java bytecode. And this can only be run by machines with the JRE, or the Java Runtime Environment, installed. So if the JRE is needed to run Java programs, what's needed to build and compile a Java program? Well, you need to install the JDK, or the Java Development Kit. The JDK is a full-featured software development kit that includes everything from the JRE as well as compilers, debuggers, and tools to create Java programs. This means we can just install the JDK, or the Java Development Kit, and we get the JRE, or the Java Runtime Environment, automatically.
随堂练习,边学边练
下载课堂讲义。学练结合,紧跟进度,轻松巩固知识。