Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import java.io.*;
- public class RandTemps {
- public static void main(String[] args) throws IOException
- {
- PrintWriter fileOut = new PrintWriter(new FileWriter("temperatures.txt"));
- for (int x=0; x<365; x++)
- {
- fileOut.println((int)(Math.random()*62+-21));
- }
- fileOut.close();
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement