常量和变量
来源:互联网 发布:mac osx 切换root 编辑:程序博客网 时间:2024/06/14 19:36
public class 变量和常量{public static void main(String[]args){int i =myText.getResult(8,16);System.out.println(i);myText wk=new myText(5,10);System.out.println(wk.MAX);}} class myText{ int i; int j; final int MAX; static int m; myText(int a,int b){ this.i=a; this.j=b; int c=getSum(i,j); this.MAX=999; System.out.println(c); } static int getResult(int a,int b){ m=getDifference(a,b); return m; } int getSum (int a ,int b){ return a+b; } static int getDifference(int a ,int b){ if(a>b){ return a-b; } else{ return b-a; } } }
0 0
- 变量和常量,数组
- 常量和变量
- 变量和常量
- 数据类型、常量和变量
- 变量和常量
- Js_常量和变量
- 字符串常量和变量
- (二) 变量和常量
- Ruby变量和常量
- go - 变量和常量
- Java 变量和常量
- 常量和变量
- Swift--变量和常量
- Swift--变量和常量
- Swift常量和变量
- 变量、常量和函数
- Swift常量和变量
- swift常量和变量
- redis学习笔记(18)---事件
- Leetcode 237. Delete Node in a Linked List
- gdb 调试利器
- Tableau Desktop简单介绍
- 快速排序2
- 常量和变量
- matlab 二进制文件的读取fead,节约内存
- Python的GIL是什么鬼,多线程性能究竟如何
- hdu2544 最短路
- 51单片机定时器精度问题之一
- Unity3D 性能优化
- 【Qt】自定义样式之QSS
- LeetCode Two Sum
- Seam Carving代码