diff --git a/.gitignore b/.gitignore
index 86c86acf7fab1ee1a9ab78458d7f79ccde5976a5..7a4a6e4d2a6adeef3329e3d20f0e9f846aa6cf9d 100644
--- a/.gitignore
+++ b/.gitignore
@@ -4,7 +4,7 @@
 .classpath
 .project
 .settings
-src
+bin
 
 # Package Files #
 *.jar
diff --git a/src/main/java/koz01/java2/lab05/Point.java b/src/main/java/koz01/java2/lab05/Point.java
index 978b02e053e63dda831deb09942f45919bcf7a51..785fee175e3316011454418258a37a7908aa2b0d 100644
--- a/src/main/java/koz01/java2/lab05/Point.java
+++ b/src/main/java/koz01/java2/lab05/Point.java
@@ -1,7 +1,26 @@
 package koz01.java2.lab05;
 
+import static java.lang.Math.PI;
+import static java.lang.Math.cos;
+
+import java.util.Random;
+
+import lombok.Getter;
+import lombok.ToString;
+
+@ToString
+@Getter
 public class Point {
 
+	public static Point randomWithGivenDistanceFromOrigin(Point start, double distance) {
+		if (distance < 0) {
+			throw new IllegalArgumentException("Distance should be non negetavi but was " + distance);
+		}
+		final Random rnd = new Random();
+		final double lambda = rnd.nextDouble(2 * PI);
+		return new Point(distance*cos(lambda) + start.x, distance*Math.sin(lambda) + start.y);
+	}
+	
 	private double x;
 	
 	private double y;
@@ -19,9 +38,18 @@ public class Point {
 		}
 		return false;
 	}
+	
+	@Override
+	public int hashCode() {
+		int val = 7;
+		val = val*31 + Double.hashCode(x);
+		val = val*31 + Double.hashCode(y);
+		return val;
+	}
 
 	protected boolean canEqual(Point point) {
 		return true;
 	}
 	
+	
 }
diff --git a/src/test/java/koz01/java2/lab05/Test.java b/src/test/java/koz01/java2/lab05/Test.java
new file mode 100644
index 0000000000000000000000000000000000000000..85fa1e9e5c91461358503077fb956048b5ec0511
--- /dev/null
+++ b/src/test/java/koz01/java2/lab05/Test.java
@@ -0,0 +1,85 @@
+package koz01.java2.lab05;
+
+import static org.junit.jupiter.api.Assertions.assertFalse;
+import static org.junit.jupiter.api.Assertions.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertTrue;
+
+import java.util.HashSet;
+import java.util.Set;
+
+import lombok.extern.log4j.Log4j2;
+
+@Log4j2
+public class Test {
+
+	@org.junit.jupiter.api.Test
+	public void testContainsPoint() {
+		Set<Point> points = new HashSet<>();
+		Point p1 = new Point(10,20);
+		Point p2 = new Point(10,30);
+		Point p3 = new Point(10,20);
+		
+		points.add(p1);
+		points.add(p2);
+		
+		assertTrue(points.contains(p1));
+		assertTrue(points.contains(p2));
+		assertTrue(p1.equals(p3));
+		assertTrue(points.contains(p3));
+	}
+	
+	@org.junit.jupiter.api.Test
+	public void testContainsString() {
+		Set<String> points = new HashSet<>();
+		String p1 = "hello";
+		String p2 = "hi";
+		String p3 = new String("hello");
+		
+		points.add(p1);
+		points.add(p2);
+		
+		assertTrue(points.contains(p1));
+		assertTrue(points.contains(p2));
+		assertTrue(p1.equals(p3));
+		assertTrue(p1 != p3);
+		assertTrue(points.contains(p3));
+	}
+	
+	@org.junit.jupiter.api.Test
+	public void testContainsPerformance() {
+		Set<Point> points = new HashSet<>();
+		Point p1 = new Point(10,20);
+		{
+			long start = System.currentTimeMillis();
+			for (long i = 0; i < 100_000l; i++) {
+				points.add(new Point(i, i));
+			}
+			long duration = System.currentTimeMillis() - start;
+			log.info("Duration of addition: {} ", (duration / 1000.));
+		}
+		{
+			long start = System.currentTimeMillis();
+			assertFalse(points.contains(p1));
+			long duration = System.currentTimeMillis() - start;
+			log.info("Duration: {}", (duration / 1000.));
+		}
+	}
+
+	@org.junit.jupiter.api.Test
+	public void testGeneration() {
+		final Point start = new Point(10, 100);
+		final Point generated = Point.randomWithGivenDistanceFromOrigin(start, 50);
+		final double distance = Math.sqrt((start.getX() - generated.getX()) * (start.getX() - generated.getX())
+				+ (start.getY() - generated.getY()) * (start.getY() - generated.getY()));
+		log.info("generated = {}, distance = {}", generated, distance);
+		
+		
+		assertThrows(IllegalArgumentException.class, () -> {
+			final Point illegal = Point.randomWithGivenDistanceFromOrigin(start, -10);
+			final double illegal_distance = Math.sqrt((start.getX() - illegal.getX()) * (start.getX() - illegal.getX())
+					+ (start.getY() - illegal.getY()) * (start.getY() - illegal.getY()));
+			log.info("generated = {}, distance = {}", illegal, illegal_distance);
+
+		});
+	}
+}