pashunov151

Untitled

May 1st, 2019
513
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.60 KB | None | 0 0
  1. package com.company;
  2.  
  3. import java.util.Scanner;
  4.  
  5. public class SoftUni {
  6.     public static void main(String[] args) {
  7.         Scanner scanner = new Scanner(System.in);
  8.         //String grade;
  9.         int sum = 0;
  10.         boolean isStop = true;
  11.         int cakesNumber = Integer.parseInt(scanner.nextLine());
  12.         for (int i = 0; i < cakesNumber; i++) {
  13.             String chef = scanner.nextLine();
  14.             do {
  15.                 String grade = scanner.nextLine();
  16.             }
  17.             while (!grade.equals("Stop")) ;
  18.            
  19.         }
  20.         System.out.println(sum);
  21.     }
  22. }
Add Comment
Please, Sign In to add comment