Monday, July 21, 2014

Load a file and print out lines in a random order


 public static void main(String args[]) throws IOException{
  List<String> lines = Files.readAllLines(Paths.get("test.txt"));
  Random r = new Random();
  while(!lines.isEmpty()){     
   String nextLine = lines.get(r.nextInt(lines.size()));
   System.out.println(nextLine);
   lines.remove(nextLine);   
  }  
 }

Saturday, February 08, 2014

Saturday, June 08, 2013

Tuesday, February 19, 2013

Too Much Technology

"Healthcare companies today are solving the medical problems that our technological society has created. Diabetes, heart disease, and obesity. The cure isn't more technology and medicine...the cure is that these people need a reason to live."

http://www.infoq.com/news/2012/01/too-much-technology