This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import java.util.List; | |
public class TestText { | |
public static void main(String[] args) { | |
Text text = new Text(); | |
List<String> words = text.convertString("i 154want this text!!! will {be} sorted, by 12digits start and then words 4length "); | |
text.printText(words); | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package testing_task; | |
import java.time.LocalDate; | |
public class Product implements Comparable<Product> { | |
private static int idCounter; | |
private int id; | |
private String name; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package testing_task; | |
import java.time.LocalDate; | |
public class Product implements Comparable<Product> { | |
private static int idCounter; | |
private int id; | |
private String name; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package loto; | |
import java.util.Arrays; | |
import java.util.Random; | |
public class Loto { | |
private int count; | |
private int happyBalls; | |
private int [] box; | |
private int [] happyBox; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package group; | |
public class Group { | |
private Person [] persons; | |
private int index; | |
public Group(int maxIndex) { | |
persons = new Person[maxIndex]; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package lesson6; | |
public class Task2 { | |
public static void main(String[] args) { | |
int [] a = {-11,-5,-23,5,6}; | |
System.out.println(sumNegative(a)); | |
} | |
public static int sumNegative (int [] a) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package homework; | |
import java.util.Scanner; | |
public class Factorial { | |
public static void main(String[] args) { | |
Scanner sc = new Scanner(System.in); | |
System.out.println("input number from 4 to 12"); | |
int a = sc.nextInt(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package homework; | |
public class Task6 { | |
public static void main(String[] args) { | |
checking(); | |
} | |
public static void checking() { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package homework; | |
import java.util.Scanner; | |
public class Factorial { | |
public static void main(String[] args) { | |
Scanner sc = new Scanner(System.in); | |
System.out.println("input number from 4 to 12"); | |
int a = sc.nextInt(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package homework; | |
public class Triangle { | |
public static void main(String[] args) { | |
drawFigure(5); | |
} | |
public static void drawFigure(int size) { |
NewerOlder