summaryrefslogtreecommitdiffstats
path: root/Java/PowerCosting.java
blob: e4eed8a3e48939539ae97920fcb1e0ea2034567e (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
//I have no clue what the formula for this is, but I think I got it right
import java.io.BufferedReader;
import java.io.InputStreamReader;

class Ohm {
    public static void main(String[] args) throws java.io.IOException {
		    float KWPH, USE; 
		    System.out.println("Put in Cost per kilowatt hour and the kilowat hours"); 
	            BufferedReader voltage = new BufferedReader(new InputStreamReader(System.in));
		    KWPH = Float.parseFloat(voltage.readLine());
		    BufferedReader resist = new BufferedReader(new InputStreamReader(System.in));
		    USE = Float.parseFloat(resist.readLine());
		    System.out.println("Annual Cost: " + KWPH*USE);
		    
                    
                    
                    

    }
}

//By msglm; Licensed under the AGPL v3