Advertisement
MJItani

Untitled

Oct 21st, 2016
80
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.32 KB | None | 0 0
  1. // part 1
  2. public static double abc(double total){
  3. int r = 0;
  4. int sum1 = 0;
  5. int s = 0;
  6. for( r=0;sum1<total;r++){
  7. s = (int) ((Math.ceil(6*Math.random()))+(Math.ceil(6*Math.random())));
  8. sum1 = sum1 +s;
  9. }
  10. return r;
  11. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement