Repository navigation
Expand file tree
/
Copy pathMk1.java
More file actions
31 lines (25 loc) · 1.98 KB
/
Copy pathMk1.java
File metadata and controls
31 lines (25 loc) · 1.98 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
class Mk1 {
public static void main(String[] args) {
int plate = 45;
int thirtyFive = 35;
int twentyFive = 25;
int ten = 10;
int five = 5;
double twoPointFive = 2.5;
double onePointTwoFive = 1.25;
double ezCurlBar = 25.0; // substitute with the actual weight of your EZ curl bar
double olympicBar = 45.0; // substitute with the actual weight of your barbell
/////////////////// SUBSTITUTE THE VALUES BELLOW FOR THE AMOUT OF WEIGHT PLATES YOUA RE USING AND FOR WHICH BARBELL YOU ARE USING /////////////////////////////////
double barUsed = ezCurlBar; // change to ezCurlBar if you are using an EZ curl bar or olympicBar if you are using a barbell
int numberOfPlates = 0; // substitute the number with the actual number of plates you have
int numberOfThirtyFive = 0; // substitute the number with the actual number of 35lb plates you have
int numberOfTwentyFive = 0; // substitute the number with the actual number of 25lb plates you have
int numberOfTen = 0; // substitute the number with the actual number of 10lb plates you have
int numberOfFive = 0; // substitute the number with the actual number of 5lb plates you have
int numberOfTwoPointFive = 0; // substitute the number with the actual number of 2.5lb plates you have
int numberOfOnePointTwoFive = 0; // substitute the number with the actual number of 1.25lb plates you have
///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
double totalWeight = barUsed + (plate * numberOfPlates) + (thirtyFive * numberOfThirtyFive) + (twentyFive * numberOfTwentyFive) + (ten * numberOfTen) + (five * numberOfFive) + (twoPointFive * numberOfTwoPointFive) + (onePointTwoFive * numberOfOnePointTwoFive);
System.out.println("Total weight: " + totalWeight + "lbs");
}
}