代码: import java.io.File; public class FileShow { static class Test12 { public static void main(String[] args) { File f = new File("C:\\Users\\19821\\D Read More
posted @ 2021-08-06 23:13 heyhy Views(616) Comments(0) Diggs(0) Edit
代码 /** * 统计给定文件中给定字符串的出现次数 * @param filename 文件名 * @param word 字符串 * @return 字符串在文件中出现的次数 */ public static int countWordInFile(String filename, String Read More
posted @ 2021-08-06 22:57 heyhy Views(166) Comments(0) Diggs(0) Edit