
java
码农—杰
这个作者很懒,什么都没留下…
展开
-
java稀疏数组转化为二维数组
package demostruct;//import java.io.FileInputStream;//import java.io.FileOutputStream;public class sparseStruct { public static void main(String[] args) throws Exception { //创立一个11*11的稀疏数组 int arr[][]=new int[11][11]; arr[1][2]=1; arr[2][3]=2;.原创 2022-01-09 21:14:35 · 350 阅读 · 0 评论 -
java成员内部类
package javaaa;class Outer{ int m=0; void test() { System.out.println("外部类方法!"); } class Inner{ int n=1; void show1() { System.out.println("外部类成员变量m="+m); test(); } void show2() { System.out.println("内部类成员方法"); } } void te.原创 2021-12-19 23:09:14 · 251 阅读 · 0 评论