Created
April 17, 2012 22:47
-
-
Save codewithcats/2409619 to your computer and use it in GitHub Desktop.
Calculate Unit Per Day - Team 8
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public int calUnit() { | |
double realval = (this.power / 1000.00) * this.duration; | |
int tem = (int) realval; | |
if (realval - tem != 0) { | |
tem += 1; | |
} | |
return tem; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment