Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import java.util.Scanner;
- public class k {
- public static void main(String[] args) {
- Scanner s = new Scanner(System.in);
- double fuelNow, tank;
- System.out.println("how mach is your fuel tank?");
- tank = s.nextDouble();
- System.out.println("how mach fuel remand?");
- fuelNow = s.nextDouble();
- if (fuelNow <= tank * 0.15) {
- System.out.println("u need to refuel your vehicle");
- } else {
- System.out.println("run Forest run");
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement