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 lecture5_practic; | |
/** | |
* Created by Xepcoh on 05.09.2016 | |
*/ | |
public class Desc { | |
public static void main(String[] args) { | |
int n = 1; | |
boolean white = true; |
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 oop.lesson1.homework.rectange; | |
public class RectangleRunner { | |
public static void main(String[] args) { | |
Rectangle[] listRectangles = {new Rectangle(8, 4), new Rectangle(5, 6), new Rectangle(7, 6)}; | |
System.out.println(sumArea(listRectangles)); | |
} |
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 oop.lesson1.homework; | |
import java.util.Scanner; | |
public class Palindromic { | |
public static void main(String[] args) { | |
int n = 4; | |
Scanner scanner = new Scanner(System.in); | |
int countResult = 0; |
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 oop.lesson1.homework; | |
import java.text.DateFormatSymbols; | |
import java.util.Scanner; | |
public class NumberMonth { | |
public static void main(String[] args) { | |
Scanner scanner = new Scanner(System.in); | |
if(!scanner.hasNextInt()) { |
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 oop.lesson2.homework.lines; | |
public class Line { | |
private final Point start; | |
private final Point stop; | |
public Line(Point start, Point stop) { | |
this.start = start; | |
this.stop = stop; |
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 oop.lesson2.homework.books; | |
import java.util.Arrays; | |
public class Book { | |
private static int nextId = 1; | |
private final int id = nextId++; | |
private final String name; | |
private final String[] authors; |
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 oop.lesson2.homework.puppy; | |
public class Animal { | |
protected String name; | |
public Animal(String name) { | |
this.name = 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
public class Directory { | |
private List<Directory> directoryList = new ArrayList<>(); | |
private List<File> fileList = new ArrayList<>(); | |
private static int dirId = 1; | |
private static int fId = 1; | |
public Directory(File file, File file1) { | |
add(file); | |
add(file1); |
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
public class Phrase { | |
private String value=""; | |
public void addValue(Word word) { | |
value += " " + word.getValue(); | |
} | |
public String getValue() { | |
return value; | |
} |
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
public class Continent { | |
private String name; | |
public Continent(String name) { | |
this.name = name; | |
} | |
public String getName() { | |
return name; | |
} |
OlderNewer