课程: Java 8+ Essential Training: Syntax and Structure
今天就学习课程吧!
今天就开通帐号,24,600 门业界名师课程任您挑!
Test simple Java code in JShell - Java教程
课程: Java 8+ Essential Training: Syntax and Structure
Test simple Java code in JShell
- [Narrator] The JShell command is a mayor new feature of Java 9. When you run JShell you can enter simple Java statements without having to create a whole application or even a Java class. This lets you test simple code before you add it to a larger software package. To run JShell from anywhere in your file system open a Command Prompt or a PowerShell on Windows, or open Terminal on Mac. Make sure you′re added the jdk′s bin directory to your system′s path. On Mac OS this is automatic but on Windows you have to do it yourself. Then, just type jshell. If you have trouble running JShell go back to the previous video on configuring the path and make sure that′s working correctly. When you′re in JShell you can type any Java statement. For example, let′s say I wanted to declare a string value. I′d start with the type of the variable, String. Now, remember, Java is case-sensitive so type it exactly as I′m showing here. Then I′ll give the variable an identifier of s1 and I′ll assign it a…
随堂练习,边学边练
下载课堂讲义。学练结合,紧跟进度,轻松巩固知识。
内容
-
-
-
-
(已锁定)
Install Java on Windows2 分钟 17 秒
-
(已锁定)
Add Java to the system PATH on Windows2 分钟 41 秒
-
(已锁定)
Install Java on OS X2 分钟 59 秒
-
(已锁定)
Test simple Java code in JShell4 分钟 49 秒
-
(已锁定)
Install and configure IntelliJ IDEA3 分钟 45 秒
-
(已锁定)
Create a project in IntelliJ IDEA6 分钟 10 秒
-
(已锁定)
Pass arguments to a console application5 分钟
-
(已锁定)
Take a tour of IntelliJ IDEA3 分钟 56 秒
-
(已锁定)
Use the Java API documentation4 分钟 24 秒
-
(已锁定)
-
-
-
-