File tree Expand file tree Collapse file tree 4 files changed +10
-10
lines changed
app/src/main/java/hexlet/code Expand file tree Collapse file tree 4 files changed +10
-10
lines changed Original file line number Diff line number Diff line change 11package hexlet .code ;
22
33import java .util .Scanner ;
4-
5- import hexlet .code .games .*;
4+ import hexlet .code .games .Even ;
5+ import hexlet .code .games .Calc ;
6+ import hexlet .code .games .GCD ;
7+ import hexlet .code .games .Progression ;
8+ import hexlet .code .games .Prime ;
69
710public class App {
811 public static void main (String [] args ) {
Original file line number Diff line number Diff line change @@ -24,11 +24,11 @@ public static void start() {
2424 var number2 = Engine .getRandomNumber (RANDOM_NUMBER_BOUND );
2525 char operator ;
2626
27- switch (Engine .getRandomNumber (RANDOM_OPERATOR_BOUND )) {
28- case 0 -> operator = '+' ;
29- case 1 -> operator = '-' ;
30- default -> operator = '*' ;
31- }
27+ operator = switch (Engine .getRandomNumber (RANDOM_OPERATOR_BOUND )) {
28+ case 0 -> '+' ;
29+ case 1 -> '-' ;
30+ default -> '*' ;
31+ };
3232
3333 var correctAnswer = calculate (number1 , number2 , operator );
3434 questions [i ] = number1 + " " + operator + " " + number2 ;
Original file line number Diff line number Diff line change 11package hexlet .code .games ;
22
3- import java .util .Scanner ;
4-
53public class GCD {
64 private static final int RANDOM_NUMBER_BOUND = 100 ;
75
Original file line number Diff line number Diff line change 11package hexlet .code .games ;
22
3- import java .util .Scanner ;
43import java .util .StringJoiner ;
54
65public class Progression {
You can’t perform that action at this time.
0 commit comments