当前位置:网站首页>Variable definition and use
Variable definition and use
2022-04-23 03:28:00 【Aiyou coffee】
Overview of variables :
Definition of variables : While the program is running , The amount of value that can change .
Variables are essentially a small area of memory .
Variable The definition of :
Variables are defined by variable names , data type , The variable value consists of three parts .
So the format is : data type Variable name = A variable's value :
for example int a = 3;
Use of variables :
Modify the format : Variable name = A variable's value
public class variable{
public static void main (String []args){
// Define a variable
int a = 1:
// Output
System.out.println(a);
// Modify variables
a =23;
// Once again, the output
System.out.println(a);
}
}
This is the process of defining and modifying variables .
matters needing attention :
1. The name cannot be repeated
2. You can't use variables without assignment
3.long When a type is defined, it should be followed by an uppercase L
4.float Type to prevent incompatibility , So add... After it F
版权声明
本文为[Aiyou coffee]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/04/202204220619009371.html
边栏推荐
- 场景题:A系统如何使用B系统的页面
- Basic use of Charles
- Codeforces Round #784 (Div. 4)题解 (第一次AK cf (XD
- 深度学习笔记(二)——激活函数原理与实现
- L3-011 直捣黄龙 (30 分)
- 批量下載文件----壓縮後再下載
- . net 5 Web custom middleware implementation returns the default picture
- Chapter 9 of C language programming (fifth edition of Tan Haoqiang) analysis and answer of exercises for users to establish their own data types
- Chapter 8 exception handling, string handling and file operation
- 集合之List接口
猜你喜欢
![Use of ADB command [1]](/img/e6/fb8fd6956c226f75b831f8eb46277f.png)
Use of ADB command [1]

Visual programming - Experiment 1

可以接收多種數據類型參數——可變參數

2022 group programming ladder simulation match 1-8 are prime numbers (20 points)

Experiment 6 input / output stream

Seminar playback video: how to improve Jenkins' ability to become a real Devops platform

Super easy to use asynchronous export function of Excel

C abstract class

Unity games and related interview questions

A comprehensive understanding of static code analysis
随机推荐
List interface of collection
Seminar playback video: how to improve Jenkins' ability to become a real Devops platform
L3-011 direct attack Huanglong (30 points)
Database SQL -- simulate inserting a large amount of data, importing / exporting database scripts, timestamp conversion and database basics
C set
Scenario Title: how does system a use the page of system B
QT learning summary
Knowledge of software testing~
通过 zxing 生成二维码
Supersocket is Use in net5 - concept
MySql关键字GROUP_CONCAT,组合连接查询
Visual programming -- how to customize the mouse cursor
Detailed description of MySQL index [B + tree index, hash index, full-text index, overlay index]
JS inheritance
PWA I'm here
Redis(17) -- Redis缓存相关问题解决
2021-08-31
深度学习笔记(二)——激活函数原理与实现
Problem C: realize Joseph Ring with linked list
Section 2 map and structure in Chapter 6