Skip to content

Commit

Permalink
Build SUCCESS
Browse files Browse the repository at this point in the history
  • Loading branch information
Alex Smechow committed Sep 18, 2024
1 parent fbd88d5 commit 4155d3f
Show file tree
Hide file tree
Showing 5 changed files with 26 additions and 29 deletions.
15 changes: 6 additions & 9 deletions src/main/java/core/basesyntax/HelloWorld.java
Original file line number Diff line number Diff line change
@@ -1,25 +1,22 @@
package core.basesyntax;

import core.basesyntax.Model.Cat;
import core.basesyntax.Model.Dog;
import core.basesyntax.model.Cat;
import core.basesyntax.model.Dog;
import java.time.LocalDate;

public class HelloWorld {
private String a;
private int variable;
private int age;
private int size;


public static void main(String[] args) {
Dog dog = new Dog();
Cat cat = new Cat();
}

private String getFromOneToTen() {
String result = "";

for(int i = 0; i < 10; i++) {
for (int i = 0; i < 10; i++) {
if (i % 2 == 0) {
result = result + i + " ";
}
Expand All @@ -29,13 +26,13 @@ private String getFromOneToTen() {

private void sayHello(String hello) {
System.out.println("Hello, Mate! I am happy to see you! This class looks weird!"
+ " Your task is to fix the checkstyle in this file."
+ " Your goal is to run `mvn clean package` and receive `BUILD SUCCESS` message");
+ " Your task is to fix the checkstyle in this file."
+ "Your goal is to run `mvn clean package` and receive `BUILD SUCCESS` message");
System.out.println(hello);
}

private void initializeVariables() {
a = "Hello mates!";
String a = "Hello mates!";
System.out.println(a);
variable = LocalDate.now().getYear();
System.out.println("It is " + variable + "year");
Expand Down
16 changes: 0 additions & 16 deletions src/main/java/core/basesyntax/Model/Cat.java

This file was deleted.

4 changes: 0 additions & 4 deletions src/main/java/core/basesyntax/Model/Dog.java

This file was deleted.

16 changes: 16 additions & 0 deletions src/main/java/core/basesyntax/model/Cat.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
package core.basesyntax.model;

public class Cat {
private int age;
private String name;
private String ownerName;

@Override
public String toString() {
return "Cat{"
+ "age=" + age
+ ", name='" + name + '\''
+ ", ownerName='" + ownerName + '\''
+ '}';
}
}
4 changes: 4 additions & 0 deletions src/main/java/core/basesyntax/model/Dog.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
package core.basesyntax.model;

public class Dog {
}

0 comments on commit 4155d3f

Please sign in to comment.