Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import java.util.Scanner;
- public class TEST {
- public static void main(String[] args) {
- Scanner scanner = new Scanner(System.in);
- String posokaOvca1 = scanner.nextLine();
- String posokaOvca2 = scanner.nextLine();
- String posokaKrokodil = scanner.nextLine();
- String colorOvca1 = scanner.nextLine();
- String colorOvca2 = scanner.nextLine();
- String colorKrokodil = scanner.nextLine();
- double priceKgAsfalt = 0;
- if (posokaOvca1.equals("left") && colorOvca2.equals("green")) {
- if (colorKrokodil.equals("white")) {
- priceKgAsfalt = Double.parseDouble(scanner.nextLine());
- }
- }
- System.out.println(priceKgAsfalt);
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement