Huang -201306114432 http://www.cnblogs.com/zzhuzi/
Fan Mingxiang -201306114431 http://www.cnblogs.com/vip-fan1234xiang/
It was TDD, and it took more than half an hour of video to do it.
Add TDD tools to the original program, make a class into TDD, and use it to generate operators;
class yy{private int max=4;private int min=1;private double w2,m2;private String ff Random random = new random ();//system.out.println (s); Public yy () {int s = random.nextint (max)% (max-min+1) + min;double x=random.nextint (max-2)% (max-2-min+1) + min;double y= Random.nextint (max-1)% (max-1-min+1) + min;int y1up= (int) Math.pow (10,x); int y1dn= (int) Math.pow (10,x-1); int y2up= (int ) Math.pow (10,y), int y2dn= (int) Math.pow (10,y-1), int x_y1=random.nextint (Y1UP)% (y1up-y1dn+1) + Y1dn;int x_y2= Random.nextint (y2up)% (y2up-y2dn+1) + y2dn;double w= (double) x_y1;double m= (double) x_y2;this.w2=w;this.m2=m; Switch (s) {case 1:{this.ff= "+"; System.out.println (w+ "+" +m+ "="); Case 2:{this.ff= "-"; System.out.println (w+ "-" +m+ "="); Case 3:{this.ff= "*"; SYSTEM.OUT.PRINTLN (w+ "*" +m+ "="); Case 4:{this.ff= "/"; System.out.println (w+ "/" +m+ "="); Public double Ret1 () {return w2;} Public double Ret2 () {return m2;} Public String Ret3 () {return ff;}}
Summary: You will learn something only if you do it yourself;
Unit Test 5.2 Insights