test2.7
来源:互联网 发布:java高级工程师工资 编辑:程序博客网 时间:2024/05/21 22:44
/*target:process class InCrementable
* methods:use definition of class Static and InCrementable;
*/
class StaticTest{static int i=47;}
class InCrementable{static void increment()
{StaticTest.i++;}}
public class Test7 {
public static void main(String[] args) {
StaticTest s=new StaticTest();
InCrementable sf=new InCrementable();
sf.increment();
System.out.println(s.i);
InCrementable.increment();
System.out.println(s.i);
}
}
* methods:use definition of class Static and InCrementable;
*/
class StaticTest{static int i=47;}
class InCrementable{static void increment()
{StaticTest.i++;}}
public class Test7 {
public static void main(String[] args) {
StaticTest s=new StaticTest();
InCrementable sf=new InCrementable();
sf.increment();
System.out.println(s.i);
InCrementable.increment();
System.out.println(s.i);
}
}
0 0
- test2.7
- Test2
- test2
- test2
- Test2
- test2
- Test2
- test2
- test2
- test2
- test2
- TEST2
- TEST2
- test2
- test2
- test2
- test2
- test2
- 字符串替换(持续更新中)
- ios Block传值
- JavaScript技巧续(命名规范)
- 数据结构之初体验
- 编译android5.0.2源码到libwebviewchromium.so时停止很长时间发生错误
- test2.7
- Linq查询基础
- 关于子函数变量生命周期以及指针的一些问题
- Oracle数据库分页
- MS(二)
- cell下载图片思路
- ubuntu tftp服务器搭建/安装/配置
- Hibernate – One-to-Many example (XML Mapping)
- Specialized Four-Digit Numbers-2196