Advertisement
raliportokali

Untitled

Apr 12th, 2020
46
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.45 KB | None | 0 0
  1. import java.util.Scanner;
  2. public class tutorial {
  3. public static void main (String[] guz) {
  4. int count = 3;
  5. double price = 2.75;
  6. char symbol = 'a';
  7. String name = "Dimo";
  8. Scanner scanner = new Scanner(System.in);
  9. count = Integer.parseInt(scanner.nextLine());
  10. price = Double.parseDouble(scanner.nextLine());
  11. System.out.printf("%s has bought %d beers for %f", name, count, price);
  12. }
  13. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement