练练手~
实现代码:
package SevenTeen;
import java.io.FileOutputStream;
public class Two {
public static void main(String[] args) throws Exception{
try{
FileOutputStream f = new FileOutputStream("f.dat");
int a = 0;
while(a < 100){
f.write((int) Math.random() * 100);
a++;
}
}catch (Exception e){
e.printStackTrace();
}
}
}