随笔分类 - java 基础
遍历文件夹内所有文件
摘要:File file = new File("文件夹路径"); File[] tempList = file.listFiles();for (int i = 0; i < tempList.length; i++) {System.out.println(tempList[i].getName());}
阅读全文
遍历map
摘要:public static void main(String[] args) { Map<String, String> map = new HashMap<String, String>(); map.put("1", "value1"); map.put("2", "value2"); map.
阅读全文
浙公网安备 33010602011771号