📄 myclass2_1.java
字号:
/* File Name:MyClass2_1.java
* 这是关于各种类型变量运算的实例。程序分别声明各种类型变量,
* 然后为它们赋予了初值,最后将这些类型变量的值输出。
*/
public class MyClass2_1 {
public static void main(String args[]) {
boolean b=false;
short sh=127;
int i=-116;
long l=123456L;
char ch='V';
float f=3.1415925F;
double d=-1.16E-7;
System.out.println("布尔型变量 b= "+b);
System.out.println("短整型变量 sh= "+sh);
System.out.println("整型变量 i= "+i);
System.out.println("长整型变量 l= "+l);
System.out.println("字符型变量 ch= "+ch);
System.out.println("浮点型变量 f= "+f);
System.out.println("双精度型变量 d= "+d);
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -