diff --git a/.idea/artifacts/TicTacToe___MinMax_jar.xml b/.idea/artifacts/TicTacToe___MinMax_jar.xml
new file mode 100644
index 0000000..994603c
--- /dev/null
+++ b/.idea/artifacts/TicTacToe___MinMax_jar.xml
@@ -0,0 +1,8 @@
+
+
+ $PROJECT_DIR$/out/artifacts/TicTacToe___MinMax_jar
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/inspectionProfiles/Project_Default.xml b/.idea/inspectionProfiles/Project_Default.xml
new file mode 100644
index 0000000..019fa30
--- /dev/null
+++ b/.idea/inspectionProfiles/Project_Default.xml
@@ -0,0 +1,6 @@
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/misc.xml b/.idea/misc.xml
index 2a824a2..d46cb7f 100644
--- a/.idea/misc.xml
+++ b/.idea/misc.xml
@@ -1,6 +1,6 @@
-
+
\ No newline at end of file
diff --git a/.idea/modules.xml b/.idea/modules.xml
index 80946f5..2506f2c 100644
--- a/.idea/modules.xml
+++ b/.idea/modules.xml
@@ -6,10 +6,11 @@
+
-
+
\ No newline at end of file
diff --git a/ATM-Machine/src/Operator.java b/ATM-Machine/src/Operator.java
index 4ccd846..5a7750a 100644
--- a/ATM-Machine/src/Operator.java
+++ b/ATM-Machine/src/Operator.java
@@ -1,3 +1,5 @@
+package src;
+
import java.util.Scanner;
public class Operator {
diff --git a/CodingChallanges/CodingChallanges.iml b/CodingChallanges/CodingChallanges.iml
index bb6b39c..14cfc9f 100644
--- a/CodingChallanges/CodingChallanges.iml
+++ b/CodingChallanges/CodingChallanges.iml
@@ -17,5 +17,15 @@
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/DemoProjects/res/laser.png b/DemoProjects/res/laser.png
new file mode 100644
index 0000000..019df66
Binary files /dev/null and b/DemoProjects/res/laser.png differ
diff --git a/DemoProjects/res/spaceship.png b/DemoProjects/res/spaceship.png
new file mode 100644
index 0000000..58f38a2
Binary files /dev/null and b/DemoProjects/res/spaceship.png differ
diff --git a/DemoProjects/src/animation/swingTimer/Board.java b/DemoProjects/src/animation/swingTimer/Board.java
new file mode 100644
index 0000000..777bbb5
--- /dev/null
+++ b/DemoProjects/src/animation/swingTimer/Board.java
@@ -0,0 +1,79 @@
+package animation.swingTimer;
+
+import java.awt.Color;
+import java.awt.Dimension;
+import java.awt.Graphics;
+import java.awt.Image;
+import java.awt.Toolkit;
+import java.awt.event.ActionEvent;
+import java.awt.event.ActionListener;
+import javax.swing.ImageIcon;
+import javax.swing.JPanel;
+import javax.swing.Timer;
+
+public class Board extends JPanel
+ implements ActionListener {
+
+ private final int B_WIDTH = 700;
+ private final int B_HEIGHT = 700;
+ private final int INITIAL_X = -40;
+ private final int INITIAL_Y = -40;
+ private final int DELAY = 5;
+
+ private Image star;
+ private Timer timer;
+ private int x, y;
+
+ public Board() {
+
+ initBoard();
+ }
+
+ private void loadImage() {
+
+ ImageIcon ii = new ImageIcon("/home/bitecoding/Pictures/star.png");
+ star = ii.getImage().getScaledInstance(50,50,Image.SCALE_DEFAULT);
+ }
+
+ private void initBoard() {
+
+ setBackground(Color.BLACK);
+ setPreferredSize(new Dimension(B_WIDTH, B_HEIGHT));
+
+ loadImage();
+
+ x = INITIAL_X;
+ y = INITIAL_Y;
+
+ timer = new Timer(DELAY, this);
+ timer.start();
+ }
+
+ @Override
+ public void paintComponent(Graphics g) {
+ super.paintComponent(g);
+
+ drawStar(g);
+ }
+
+ private void drawStar(Graphics g) {
+
+ g.drawImage(star, x, y, this);
+ Toolkit.getDefaultToolkit().sync();
+ }
+
+ @Override
+ public void actionPerformed(ActionEvent e) {
+
+ x += 10;
+ y += 10;
+
+ if (y > B_HEIGHT) {
+
+ y = INITIAL_Y;
+ x = INITIAL_X;
+ }
+
+ repaint();
+ }
+}
\ No newline at end of file
diff --git a/DemoProjects/src/animation/swingTimer/SwingTimer.java b/DemoProjects/src/animation/swingTimer/SwingTimer.java
new file mode 100644
index 0000000..0e51007
--- /dev/null
+++ b/DemoProjects/src/animation/swingTimer/SwingTimer.java
@@ -0,0 +1,32 @@
+package animation.swingTimer;
+
+import java.awt.EventQueue;
+import javax.swing.JFrame;
+
+public class SwingTimer extends JFrame {
+
+ public SwingTimer() {
+
+ initUI();
+ }
+
+ private void initUI() {
+
+ add(new Board());
+
+ setResizable(false);
+ pack();
+
+ setTitle("Star");
+ setLocationRelativeTo(null);
+ setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
+ }
+
+ public static void main(String[] args) {
+
+ EventQueue.invokeLater(() -> {
+ SwingTimer ex = new SwingTimer();
+ ex.setVisible(true);
+ });
+ }
+}
\ No newline at end of file
diff --git a/DemoProjects/src/animation/thread/Board.java b/DemoProjects/src/animation/thread/Board.java
new file mode 100644
index 0000000..2b3a1cd
--- /dev/null
+++ b/DemoProjects/src/animation/thread/Board.java
@@ -0,0 +1,112 @@
+package animation.thread;
+
+import java.awt.Color;
+import java.awt.Dimension;
+import java.awt.Graphics;
+import java.awt.Image;
+import java.awt.Toolkit;
+import javax.swing.ImageIcon;
+import javax.swing.JOptionPane;
+import javax.swing.JPanel;
+
+public class Board extends JPanel
+ implements Runnable {
+
+ private final int B_WIDTH = 350;
+ private final int B_HEIGHT = 350;
+ private final int INITIAL_X = -40;
+ private final int INITIAL_Y = -40;
+ private final int DELAY = 25;
+
+ private Image star;
+ private Thread animator;
+ private int x, y;
+
+ public Board() {
+
+ initBoard();
+ }
+
+ private void loadImage() {
+
+ ImageIcon ii = new ImageIcon("/home/bitecoding/Pictures/star.png");
+ star = ii.getImage().getScaledInstance(50,50, Image.SCALE_DEFAULT);
+ }
+
+ private void initBoard() {
+
+ setBackground(Color.BLACK);
+ setPreferredSize(new Dimension(B_WIDTH, B_HEIGHT));
+
+ loadImage();
+
+ x = INITIAL_X;
+ y = INITIAL_Y;
+ }
+
+ @Override
+ public void addNotify() {
+ super.addNotify();
+
+ animator = new Thread(this);
+ animator.start();
+ }
+
+ @Override
+ public void paintComponent(Graphics g) {
+ super.paintComponent(g);
+
+ drawStar(g);
+ }
+
+ private void drawStar(Graphics g) {
+
+ g.drawImage(star, x, y, this);
+ Toolkit.getDefaultToolkit().sync();
+ }
+
+ private void cycle() {
+
+ x += 1;
+ y += 1;
+
+ if (y > B_HEIGHT) {
+
+ y = INITIAL_Y;
+ x = INITIAL_X;
+ }
+ }
+
+ @Override
+ public void run() {
+
+ long beforeTime, timeDiff, sleep;
+
+ beforeTime = System.currentTimeMillis();
+
+ while (true) {
+
+ cycle();
+ repaint();
+
+ timeDiff = System.currentTimeMillis() - beforeTime;
+ sleep = DELAY - timeDiff;
+
+ if (sleep < 0) {
+ sleep = 2;
+ }
+
+ try {
+ Thread.sleep(sleep);
+ } catch (InterruptedException e) {
+
+ String msg = String.format("Thread interrupted: %s", e.getMessage());
+
+ JOptionPane.showMessageDialog(this, msg, "Error",
+ JOptionPane.ERROR_MESSAGE);
+ }
+
+ beforeTime = System.currentTimeMillis();
+ }
+ }
+}
\ No newline at end of file
diff --git a/DemoProjects/src/animation/thread/ThreadAnimation.java b/DemoProjects/src/animation/thread/ThreadAnimation.java
new file mode 100644
index 0000000..ed49049
--- /dev/null
+++ b/DemoProjects/src/animation/thread/ThreadAnimation.java
@@ -0,0 +1,32 @@
+package animation.thread;
+
+import java.awt.EventQueue;
+import javax.swing.JFrame;
+
+public class ThreadAnimation extends JFrame {
+
+ public ThreadAnimation() {
+
+ initUI();
+ }
+
+ private void initUI() {
+
+ add(new Board());
+
+ setResizable(false);
+ pack();
+
+ setTitle("Star");
+ setLocationRelativeTo(null);
+ setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
+ }
+
+ public static void main(String[] args) {
+
+ EventQueue.invokeLater(() -> {
+ JFrame ex = new ThreadAnimation();
+ ex.setVisible(true);
+ });
+ }
+}
\ No newline at end of file
diff --git a/DemoProjects/src/animation/utilityTimer/Board.java b/DemoProjects/src/animation/utilityTimer/Board.java
new file mode 100644
index 0000000..807bff1
--- /dev/null
+++ b/DemoProjects/src/animation/utilityTimer/Board.java
@@ -0,0 +1,81 @@
+package animation.utilityTimer;
+
+import java.awt.Color;
+import java.awt.Dimension;
+import java.awt.Graphics;
+import java.awt.Image;
+import java.awt.Toolkit;
+import java.util.Timer;
+import java.util.TimerTask;
+import javax.swing.ImageIcon;
+import javax.swing.JPanel;
+
+public class Board extends JPanel {
+
+ private final int B_WIDTH = 350;
+ private final int B_HEIGHT = 350;
+ private final int INITIAL_X = -40;
+ private final int INITIAL_Y = -40;
+ private final int INITIAL_DELAY = 0;
+ private final int PERIOD_INTERVAL = 25;
+
+ private Image star;
+ private Timer timer;
+ private int x, y;
+
+ public Board() {
+
+ initBoard();
+ }
+
+ private void loadImage() {
+
+ ImageIcon ii = new ImageIcon("/home/bitecoding/Pictures/star.png");
+ star = ii.getImage().getScaledInstance(50,50,Image.SCALE_DEFAULT);
+ }
+
+ private void initBoard() {
+
+ setBackground(Color.BLACK);
+ setPreferredSize(new Dimension(B_WIDTH, B_HEIGHT));
+
+ loadImage();
+
+ x = INITIAL_X;
+ y = INITIAL_Y;
+
+ timer = new Timer();
+ timer.scheduleAtFixedRate(new ScheduleTask(),
+ INITIAL_DELAY, PERIOD_INTERVAL);
+ }
+
+ @Override
+ public void paintComponent(Graphics g) {
+ super.paintComponent(g);
+
+ drawStar(g);
+ }
+
+ private void drawStar(Graphics g) {
+
+ g.drawImage(star, x, y, this);
+ Toolkit.getDefaultToolkit().sync();
+ }
+
+ private class ScheduleTask extends TimerTask {
+
+ @Override
+ public void run() {
+
+ x += 1;
+ y += 1;
+
+ if (y > B_HEIGHT) {
+ y = INITIAL_Y;
+ x = INITIAL_X;
+ }
+
+ repaint();
+ }
+ }
+}
\ No newline at end of file
diff --git a/DemoProjects/src/animation/utilityTimer/UtilityTimer.java b/DemoProjects/src/animation/utilityTimer/UtilityTimer.java
new file mode 100644
index 0000000..705ce67
--- /dev/null
+++ b/DemoProjects/src/animation/utilityTimer/UtilityTimer.java
@@ -0,0 +1,32 @@
+package animation.utilityTimer;
+
+import java.awt.EventQueue;
+import javax.swing.JFrame;
+
+public class UtilityTimer extends JFrame {
+
+ public UtilityTimer() {
+
+ initUI();
+ }
+
+ private void initUI() {
+
+ add(new Board());
+
+ setResizable(false);
+ pack();
+
+ setTitle("Star");
+ setLocationRelativeTo(null);
+ setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
+ }
+
+ public static void main(String[] args) {
+
+ EventQueue.invokeLater(() -> {
+ JFrame ex = new UtilityTimer();
+ ex.setVisible(true);
+ });
+ }
+}
\ No newline at end of file
diff --git a/DemoProjects/src/painting/SwingPaintDemo1.java b/DemoProjects/src/painting/SwingPaintDemo/SwingPaintDemo1.java
similarity index 94%
rename from DemoProjects/src/painting/SwingPaintDemo1.java
rename to DemoProjects/src/painting/SwingPaintDemo/SwingPaintDemo1.java
index 7a254ea..369044b 100644
--- a/DemoProjects/src/painting/SwingPaintDemo1.java
+++ b/DemoProjects/src/painting/SwingPaintDemo/SwingPaintDemo1.java
@@ -1,4 +1,4 @@
-package painting;
+package painting.SwingPaintDemo;
import javax.swing.SwingUtilities;
import javax.swing.JFrame;
diff --git a/DemoProjects/src/painting/SwingPaintDemo2.java b/DemoProjects/src/painting/SwingPaintDemo/SwingPaintDemo2.java
similarity index 97%
rename from DemoProjects/src/painting/SwingPaintDemo2.java
rename to DemoProjects/src/painting/SwingPaintDemo/SwingPaintDemo2.java
index 3b4dbd6..6efa0ef 100644
--- a/DemoProjects/src/painting/SwingPaintDemo2.java
+++ b/DemoProjects/src/painting/SwingPaintDemo/SwingPaintDemo2.java
@@ -1,4 +1,4 @@
-package painting;
+package painting.SwingPaintDemo;
import javax.swing.SwingUtilities;
import javax.swing.JFrame;
diff --git a/DemoProjects/src/painting/SwingPaintDemo3.java b/DemoProjects/src/painting/SwingPaintDemo/SwingPaintDemo3.java
similarity index 93%
rename from DemoProjects/src/painting/SwingPaintDemo3.java
rename to DemoProjects/src/painting/SwingPaintDemo/SwingPaintDemo3.java
index 82da620..6310645 100644
--- a/DemoProjects/src/painting/SwingPaintDemo3.java
+++ b/DemoProjects/src/painting/SwingPaintDemo/SwingPaintDemo3.java
@@ -1,4 +1,4 @@
-package painting;
+package painting.SwingPaintDemo;
import javax.swing.SwingUtilities;
import javax.swing.JFrame;
@@ -8,10 +8,7 @@ import java.awt.Color;
import java.awt.Dimension;
import java.awt.Graphics;
import java.awt.event.MouseEvent;
-import java.awt.event.MouseListener;
import java.awt.event.MouseAdapter;
-import java.awt.event.MouseMotionListener;
-import java.awt.event.MouseMotionAdapter;
public class SwingPaintDemo3 {
diff --git a/DemoProjects/src/painting/SwingPaintDemo4.java b/DemoProjects/src/painting/SwingPaintDemo/SwingPaintDemo4.java
similarity index 99%
rename from DemoProjects/src/painting/SwingPaintDemo4.java
rename to DemoProjects/src/painting/SwingPaintDemo/SwingPaintDemo4.java
index f6dd572..cd0e140 100644
--- a/DemoProjects/src/painting/SwingPaintDemo4.java
+++ b/DemoProjects/src/painting/SwingPaintDemo/SwingPaintDemo4.java
@@ -1,4 +1,4 @@
-package painting;
+package painting.SwingPaintDemo;
import javax.swing.SwingUtilities;
import javax.swing.JFrame;
diff --git a/DemoProjects/src/painting/donut/Board.java b/DemoProjects/src/painting/donut/Board.java
new file mode 100644
index 0000000..a404f2b
--- /dev/null
+++ b/DemoProjects/src/painting/donut/Board.java
@@ -0,0 +1,50 @@
+package painting.donut;
+
+import java.awt.BasicStroke;
+import java.awt.Color;
+import java.awt.Dimension;
+import java.awt.Graphics;
+import java.awt.Graphics2D;
+import java.awt.RenderingHints;
+import java.awt.geom.AffineTransform;
+import java.awt.geom.Ellipse2D;
+import javax.swing.JPanel;
+
+public class Board extends JPanel {
+
+ @Override
+ public void paintComponent(Graphics g) {
+ super.paintComponent(g);
+
+ drawDonut(g);
+ }
+
+ private void drawDonut(Graphics g) {
+
+ Graphics2D g2d = (Graphics2D) g;
+
+ RenderingHints rh
+ = new RenderingHints(RenderingHints.KEY_ANTIALIASING,
+ RenderingHints.VALUE_ANTIALIAS_ON);
+
+ rh.put(RenderingHints.KEY_RENDERING,
+ RenderingHints.VALUE_RENDER_QUALITY);
+
+ g2d.setRenderingHints(rh);
+
+ Dimension size = getSize();
+ double w = size.getWidth();
+ double h = size.getHeight();
+
+ Ellipse2D e = new Ellipse2D.Double(0, 0, 80, 130);
+ g2d.setStroke(new BasicStroke(1));
+ g2d.setColor(Color.gray);
+
+ for (double deg = 0; deg < 360; deg += 10) {
+ AffineTransform at
+ = AffineTransform.getTranslateInstance(w/2, h/2);
+ at.rotate(Math.toRadians(deg));
+ g2d.draw(at.createTransformedShape(e));
+ }
+ }
+}
\ No newline at end of file
diff --git a/DemoProjects/src/painting/donut/Donut.java b/DemoProjects/src/painting/donut/Donut.java
new file mode 100644
index 0000000..7ba6ef5
--- /dev/null
+++ b/DemoProjects/src/painting/donut/Donut.java
@@ -0,0 +1,31 @@
+package painting.donut;
+
+import java.awt.EventQueue;
+import javax.swing.JFrame;
+
+public class Donut extends JFrame {
+
+ public Donut() {
+
+ initUI();
+ }
+
+ private void initUI() {
+
+ add(new Board());
+
+ setSize(330, 330);
+
+ setTitle("Donut");
+ setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
+ setLocationRelativeTo(null);
+ }
+
+ public static void main(String[] args) {
+
+ EventQueue.invokeLater(() -> {
+ Donut ex = new Donut();
+ ex.setVisible(true);
+ });
+ }
+}
\ No newline at end of file
diff --git a/DemoProjects/src/painting/image/Board.java b/DemoProjects/src/painting/image/Board.java
new file mode 100644
index 0000000..8c9c8e8
--- /dev/null
+++ b/DemoProjects/src/painting/image/Board.java
@@ -0,0 +1,38 @@
+package painting.image;
+
+import java.awt.Dimension;
+import java.awt.Graphics;
+import java.awt.Image;
+import javax.swing.ImageIcon;
+import javax.swing.JPanel;
+
+public class Board extends JPanel {
+
+ private Image bardejov;
+
+ public Board() {
+
+ initBoard();
+ }
+
+ private void initBoard() {
+
+ loadImage();
+
+ int w = bardejov.getWidth(this);
+ int h = bardejov.getHeight(this);
+ setPreferredSize(new Dimension(w, h));
+ }
+
+ private void loadImage() {
+
+ ImageIcon ii = new ImageIcon("/home/bitecoding/Pictures/1182657.jpg");
+ bardejov = ii.getImage();
+ }
+
+ @Override
+ public void paintComponent(Graphics g) {
+
+ g.drawImage(bardejov, 0, 0, null);
+ }
+}
diff --git a/DemoProjects/src/painting/image/Image.java b/DemoProjects/src/painting/image/Image.java
new file mode 100644
index 0000000..0b851bb
--- /dev/null
+++ b/DemoProjects/src/painting/image/Image.java
@@ -0,0 +1,27 @@
+package painting.image;
+
+import java.awt.EventQueue;
+import javax.swing.JFrame;
+
+public class Image extends JFrame {
+
+ public Image() {
+ initUI();
+ }
+
+ private void initUI() {
+ add(new Board());
+ pack();
+ setTitle("Bardejov");
+ setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
+ setLocationRelativeTo(null);
+ }
+
+ public static void main(String[] args) {
+
+ EventQueue.invokeLater(() -> {
+ Image ex = new Image();
+ ex.setVisible(true);
+ });
+ }
+}
diff --git a/DemoProjects/src/sprites/shootingMissles/Board.java b/DemoProjects/src/sprites/shootingMissles/Board.java
new file mode 100644
index 0000000..2e6ed6f
--- /dev/null
+++ b/DemoProjects/src/sprites/shootingMissles/Board.java
@@ -0,0 +1,100 @@
+package sprites.shootingMissles;
+
+import javax.swing.*;
+import java.awt.*;
+import java.awt.event.ActionEvent;
+import java.awt.event.ActionListener;
+import java.awt.event.KeyAdapter;
+import java.awt.event.KeyEvent;
+import java.util.List;
+
+public class Board extends JPanel implements ActionListener {
+
+ private final int ICRAFT_X = 40;
+ private final int ICRAFT_Y = 60;
+ private final int DELAY = 10;
+ private Timer timer;
+ private SpaceShip spaceShip;
+
+ public Board() {
+
+ initBoard();
+ }
+
+ private void initBoard() {
+
+ addKeyListener(new TAdapter());
+ setBackground(Color.BLACK);
+ setFocusable(true);
+
+ spaceShip = new SpaceShip(ICRAFT_X, ICRAFT_Y);
+
+ timer = new Timer(DELAY, this);
+ timer.start();
+ }
+
+ @Override
+ public void paintComponent(Graphics g) {
+ super.paintComponent(g);
+
+ doDrawing(g);
+
+ Toolkit.getDefaultToolkit().sync();
+ }
+
+ private void doDrawing(Graphics g) {
+
+ Graphics2D g2d = (Graphics2D) g;
+
+ g2d.drawImage(spaceShip.getImage(), spaceShip.getX(),
+ spaceShip.getY(), this);
+
+ List missiles = spaceShip.getMissiles();
+
+ for (Missile missile : missiles) {
+
+ g2d.drawImage(missile.getImage(), missile.getX(),
+ missile.getY(), this);
+ }
+ }
+
+ @Override
+ public void actionPerformed(ActionEvent e) {
+
+ updateMissiles();
+ updateSpaceShip();
+
+ repaint();
+ }
+
+ private void updateMissiles() {
+
+ List missiles = spaceShip.getMissiles();
+
+ for (int i = 0; i < missiles.size(); i++) {
+ Missile missile = missiles.get(i);
+ if (missile.isVisible()) {
+ missile.move();
+ } else {
+ missiles.remove(i);
+ }
+ }
+ }
+
+ private void updateSpaceShip() {
+ spaceShip.move();
+ }
+
+ private class TAdapter extends KeyAdapter {
+
+ @Override
+ public void keyReleased(KeyEvent e) {
+ spaceShip.keyReleased(e);
+ }
+
+ @Override
+ public void keyPressed(KeyEvent e) {
+ spaceShip.keyPressed(e);
+ }
+ }
+}
\ No newline at end of file
diff --git a/DemoProjects/src/sprites/shootingMissles/Executor.java b/DemoProjects/src/sprites/shootingMissles/Executor.java
new file mode 100644
index 0000000..d115fbb
--- /dev/null
+++ b/DemoProjects/src/sprites/shootingMissles/Executor.java
@@ -0,0 +1,32 @@
+package sprites.shootingMissles;
+
+import java.awt.EventQueue;
+import javax.swing.JFrame;
+
+public class Executor extends JFrame {
+
+ public Executor() {
+
+ initUI();
+ }
+
+ private void initUI() {
+
+ add(new Board());
+
+ setSize(400, 300);
+ setResizable(false);
+
+ setTitle("Shooting missiles");
+ setLocationRelativeTo(null);
+ setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
+ }
+
+ public static void main(String[] args) {
+
+ EventQueue.invokeLater(() -> {
+ Executor ex = new Executor();
+ ex.setVisible(true);
+ });
+ }
+}
\ No newline at end of file
diff --git a/DemoProjects/src/sprites/shootingMissles/Missile.java b/DemoProjects/src/sprites/shootingMissles/Missile.java
new file mode 100644
index 0000000..8b50ee2
--- /dev/null
+++ b/DemoProjects/src/sprites/shootingMissles/Missile.java
@@ -0,0 +1,26 @@
+package sprites.shootingMissles;
+
+public class Missile extends Sprite {
+
+ private final int MISSILE_SPEED = 2;
+ private final int FRAME_WIDTH = 400;
+
+ public Missile(int x, int y) {
+ super(x, y);
+
+ initMissile();
+ }
+
+ private void initMissile() {
+ loadImage("DemoProjects/res/laser.png",100,10);
+ }
+
+ public void move() {
+
+ x += MISSILE_SPEED;
+
+ if (x > FRAME_WIDTH) {
+ visible = false;
+ }
+ }
+}
\ No newline at end of file
diff --git a/DemoProjects/src/sprites/shootingMissles/SpaceShip.java b/DemoProjects/src/sprites/shootingMissles/SpaceShip.java
new file mode 100644
index 0000000..8a4a23e
--- /dev/null
+++ b/DemoProjects/src/sprites/shootingMissles/SpaceShip.java
@@ -0,0 +1,84 @@
+package sprites.shootingMissles;
+
+import java.awt.event.KeyEvent;
+import java.util.ArrayList;
+import java.util.List;
+
+public class SpaceShip extends Sprite {
+
+ private int dx;
+ private int dy;
+ private List missiles;
+
+ public SpaceShip(int x, int y) {
+ super(x, y);
+
+ initSpaceShip();
+ }
+
+ private void initSpaceShip() {
+
+ missiles = new ArrayList<>();
+
+ loadImage("DemoProjects/res/spaceship.png",50,50);
+ }
+
+ public void move() {
+ x += dx;
+ y += dy;
+ }
+
+ public List getMissiles() {
+ return missiles;
+ }
+
+ public void keyPressed(KeyEvent e) {
+
+ int key = e.getKeyCode();
+
+ if (key == KeyEvent.VK_SPACE) {
+ fire();
+ }
+
+ if (key == KeyEvent.VK_LEFT) {
+ dx = -1;
+ }
+
+ if (key == KeyEvent.VK_RIGHT) {
+ dx = 1;
+ }
+
+ if (key == KeyEvent.VK_UP) {
+ dy = -1;
+ }
+
+ if (key == KeyEvent.VK_DOWN) {
+ dy = 1;
+ }
+ }
+
+ public void fire() {
+ missiles.add(new Missile(x - width/2, y + height/2 - 5));
+ }
+
+ public void keyReleased(KeyEvent e) {
+
+ int key = e.getKeyCode();
+
+ if (key == KeyEvent.VK_LEFT) {
+ dx = 0;
+ }
+
+ if (key == KeyEvent.VK_RIGHT) {
+ dx = 0;
+ }
+
+ if (key == KeyEvent.VK_UP) {
+ dy = 0;
+ }
+
+ if (key == KeyEvent.VK_DOWN) {
+ dy = 0;
+ }
+ }
+}
\ No newline at end of file
diff --git a/DemoProjects/src/sprites/shootingMissles/Sprite.java b/DemoProjects/src/sprites/shootingMissles/Sprite.java
new file mode 100644
index 0000000..f756631
--- /dev/null
+++ b/DemoProjects/src/sprites/shootingMissles/Sprite.java
@@ -0,0 +1,53 @@
+package sprites.shootingMissles;
+
+import java.awt.*;
+import java.awt.image.BufferedImage;
+import java.io.File;
+import java.io.IOException;
+import javax.imageio.ImageIO;
+import javax.swing.ImageIcon;
+
+public class Sprite {
+
+ protected int x;
+ protected int y;
+ protected int width;
+ protected int height;
+ protected boolean visible;
+ protected String path;
+ protected Image image;
+
+ public Sprite(int x, int y) {
+ this.x = x;
+ this.y = y;
+ visible = true;
+ }
+
+ protected void loadImage(String imageName, int width, int height) {
+ path = imageName;
+ ImageIcon ii = new ImageIcon(imageName);
+ image = ii.getImage().getScaledInstance(width, height, Image.SCALE_DEFAULT);
+ this.width = width;
+ this.height = height;
+ }
+
+ public Image getImage() {
+ return image;
+ }
+
+ public int getX() {
+ return x;
+ }
+
+ public int getY() {
+ return y;
+ }
+
+ public boolean isVisible() {
+ return visible;
+ }
+
+ public void setVisible(Boolean visible) {
+ this.visible = visible;
+ }
+}
\ No newline at end of file
diff --git a/DemoProjects/src/sprites/spaceship/Board.java b/DemoProjects/src/sprites/spaceship/Board.java
new file mode 100644
index 0000000..db5b303
--- /dev/null
+++ b/DemoProjects/src/sprites/spaceship/Board.java
@@ -0,0 +1,79 @@
+package sprites.spaceship;
+
+import java.awt.Color;
+import java.awt.Graphics;
+import java.awt.Graphics2D;
+import java.awt.Toolkit;
+import java.awt.event.ActionEvent;
+import java.awt.event.ActionListener;
+import java.awt.event.KeyAdapter;
+import java.awt.event.KeyEvent;
+import javax.swing.JPanel;
+import javax.swing.Timer;
+
+public class Board extends JPanel implements ActionListener {
+
+ private Timer timer;
+ private SpaceShip spaceShip;
+ private final int DELAY = 10;
+
+ public Board() {
+
+ initBoard();
+ }
+
+ private void initBoard() {
+
+ addKeyListener(new TAdapter());
+ setBackground(Color.black);
+ setFocusable(true);
+
+ spaceShip = new SpaceShip();
+
+ timer = new Timer(DELAY, this);
+ timer.start();
+ }
+
+ @Override
+ public void paintComponent(Graphics g) {
+ super.paintComponent(g);
+
+ doDrawing(g);
+
+ Toolkit.getDefaultToolkit().sync();
+ }
+
+ private void doDrawing(Graphics g) {
+
+ Graphics2D g2d = (Graphics2D) g;
+
+ g2d.drawImage(spaceShip.getImage(), spaceShip.getX(),
+ spaceShip.getY(), this);
+ }
+
+ @Override
+ public void actionPerformed(ActionEvent e) {
+
+ step();
+ }
+
+ private void step() {
+
+ spaceShip.move();
+
+ repaint();
+ }
+
+ private class TAdapter extends KeyAdapter {
+
+ @Override
+ public void keyReleased(KeyEvent e) {
+ spaceShip.keyReleased(e);
+ }
+
+ @Override
+ public void keyPressed(KeyEvent e) {
+ spaceShip.keyPressed(e);
+ }
+ }
+}
\ No newline at end of file
diff --git a/DemoProjects/src/sprites/spaceship/MovingSprite.java b/DemoProjects/src/sprites/spaceship/MovingSprite.java
new file mode 100644
index 0000000..ad55218
--- /dev/null
+++ b/DemoProjects/src/sprites/spaceship/MovingSprite.java
@@ -0,0 +1,32 @@
+package sprites.spaceship;
+
+import java.awt.EventQueue;
+import javax.swing.JFrame;
+
+public class MovingSprite extends JFrame {
+
+ public MovingSprite() {
+
+ initUI();
+ }
+
+ private void initUI() {
+
+ add(new Board());
+
+ setTitle("Moving sprite");
+ setSize(400, 300);
+
+ setLocationRelativeTo(null);
+ setResizable(false);
+ setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
+ }
+
+ public static void main(String[] args) {
+
+ EventQueue.invokeLater(() -> {
+ MovingSprite ex = new MovingSprite();
+ ex.setVisible(true);
+ });
+ }
+}
\ No newline at end of file
diff --git a/DemoProjects/src/sprites/spaceship/SpaceShip.java b/DemoProjects/src/sprites/spaceship/SpaceShip.java
new file mode 100644
index 0000000..302e35b
--- /dev/null
+++ b/DemoProjects/src/sprites/spaceship/SpaceShip.java
@@ -0,0 +1,105 @@
+package sprites.spaceship;
+
+import java.awt.Image;
+import java.awt.event.KeyEvent;
+import javax.swing.ImageIcon;
+
+public class SpaceShip {
+
+ private int dx;
+ private int dy;
+ private int x = 40;
+ private int y = 60;
+ private int w;
+ private int h;
+ private Image image;
+
+ public SpaceShip() {
+
+ loadImage();
+ }
+
+ private void loadImage() {
+
+ ImageIcon ii = new ImageIcon("/home/bitecoding/Pictures/spaceship.png");
+ image = ii.getImage().getScaledInstance(50,50,1);
+
+ w = image.getWidth(null);
+ h = image.getHeight(null);
+ }
+
+ public void move() {
+
+ x += dx;
+ y += dy;
+ }
+
+ public int getX() {
+
+ return x;
+ }
+
+ public int getY() {
+
+ return y;
+ }
+
+ public int getWidth() {
+
+ return w;
+ }
+
+ public int getHeight() {
+
+ return h;
+ }
+
+ public Image getImage() {
+
+ return image;
+ }
+
+ public void keyPressed(KeyEvent e) {
+
+ int key = e.getKeyCode();
+
+ switch(key){
+ case KeyEvent.VK_A:
+ dx = -2;
+ break;
+ case KeyEvent.VK_D:
+ dx = 2;
+ break;
+ case KeyEvent.VK_W:
+ dy = -2;
+ break;
+ case KeyEvent.VK_S:
+ dy = 2;
+ break;
+ default:
+ break;
+ }
+ }
+
+ public void keyReleased(KeyEvent e) {
+
+ int key = e.getKeyCode();
+
+ switch(key){
+ case KeyEvent.VK_A:
+ dx = 0;
+ break;
+ case KeyEvent.VK_D:
+ dx = 0;
+ break;
+ case KeyEvent.VK_W:
+ dy = 0;
+ break;
+ case KeyEvent.VK_S:
+ dy = 0;
+ break;
+ default:
+ break;
+ }
+ }
+}
\ No newline at end of file
diff --git a/TicTacToe_MinMax/TicTacToe_MinMax.iml b/Doodles/Doodles.iml
similarity index 100%
rename from TicTacToe_MinMax/TicTacToe_MinMax.iml
rename to Doodles/Doodles.iml
diff --git a/Doodles/src/Template.java b/Doodles/src/Template.java
new file mode 100644
index 0000000..e79beb3
--- /dev/null
+++ b/Doodles/src/Template.java
@@ -0,0 +1,23 @@
+import java.util.Arrays;
+
+public class Template {
+
+ /*
+ 1 2 3 4 5
+ 12 13 14 15 6
+ 11 10 9 8 7
+
+ */
+
+ public static void main(String[] args) {
+ int num = 1000;
+ for (int j = 0; j < 50; j++) {
+ for (int i = 0; i < 59; i++) {
+ System.out.print(num+" ");
+ num++;
+ }
+ System.out.println();
+ }
+ }
+
+}
diff --git a/TOOLS/TOOLS.iml b/TOOLS/TOOLS.iml
index e2b0bb6..1a19db0 100644
--- a/TOOLS/TOOLS.iml
+++ b/TOOLS/TOOLS.iml
@@ -7,6 +7,7 @@
+
diff --git a/TOOLS/dataStructure/BinaryTree.java b/TOOLS/dataStructure/BinaryTree.java
new file mode 100644
index 0000000..e5f6c4f
--- /dev/null
+++ b/TOOLS/dataStructure/BinaryTree.java
@@ -0,0 +1,225 @@
+import java.util.LinkedList;
+import java.util.Queue;
+import java.util.Stack;
+
+public class BinaryTree {
+
+ Node root;
+
+ public void add(int value) {
+ root = addRecursive(root, value);
+ }
+
+ private Node addRecursive(Node current, int value) {
+
+ if (current == null) {
+ return new Node(value);
+ }
+
+ if (value < current.value) {
+ current.left = addRecursive(current.left, value);
+ } else if (value > current.value) {
+ current.right = addRecursive(current.right, value);
+ }
+
+ return current;
+ }
+
+ public boolean isEmpty() {
+ return root == null;
+ }
+
+ public int getSize() {
+ return getSizeRecursive(root);
+ }
+
+ private int getSizeRecursive(Node current) {
+ return current == null ? 0 : getSizeRecursive(current.left) + 1 + getSizeRecursive(current.right);
+ }
+
+ public boolean containsNode(int value) {
+ return containsNodeRecursive(root, value);
+ }
+
+ private boolean containsNodeRecursive(Node current, int value) {
+ if (current == null) {
+ return false;
+ }
+
+ if (value == current.value) {
+ return true;
+ }
+
+ return value < current.value
+ ? containsNodeRecursive(current.left, value)
+ : containsNodeRecursive(current.right, value);
+ }
+
+ public void delete(int value) {
+ root = deleteRecursive(root, value);
+ }
+
+ private Node deleteRecursive(Node current, int value) {
+ if (current == null) {
+ return null;
+ }
+
+ if (value == current.value) {
+ // Case 1: no children
+ if (current.left == null && current.right == null) {
+ return null;
+ }
+
+ // Case 2: only 1 child
+ if (current.right == null) {
+ return current.left;
+ }
+
+ if (current.left == null) {
+ return current.right;
+ }
+
+ // Case 3: 2 children
+ int smallestValue = findSmallestValue(current.right);
+ current.value = smallestValue;
+ current.right = deleteRecursive(current.right, smallestValue);
+ return current;
+ }
+ if (value < current.value) {
+ current.left = deleteRecursive(current.left, value);
+ return current;
+ }
+
+ current.right = deleteRecursive(current.right, value);
+ return current;
+ }
+
+ private int findSmallestValue(Node root) {
+ return root.left == null ? root.value : findSmallestValue(root.left);
+ }
+
+ public void traverseInOrder(Node node) {
+ if (node != null) {
+ traverseInOrder(node.left);
+ visit(node.value);
+ traverseInOrder(node.right);
+ }
+ }
+
+ public void traversePreOrder(Node node) {
+ if (node != null) {
+ visit(node.value);
+ traversePreOrder(node.left);
+ traversePreOrder(node.right);
+ }
+ }
+
+ public void traversePostOrder(Node node) {
+ if (node != null) {
+ traversePostOrder(node.left);
+ traversePostOrder(node.right);
+ visit(node.value);
+ }
+ }
+
+ public void traverseLevelOrder() {
+ if (root == null) {
+ return;
+ }
+
+ Queue nodes = new LinkedList<>();
+ nodes.add(root);
+
+ while (!nodes.isEmpty()) {
+
+ Node node = nodes.remove();
+
+ System.out.print(" " + node.value);
+
+ if (node.left != null) {
+ nodes.add(node.left);
+ }
+
+ if (node.right != null) {
+ nodes.add(node.right);
+ }
+ }
+ }
+
+
+ public void traverseInOrderWithoutRecursion() {
+ Stack stack = new Stack();
+ Node current = root;
+ stack.push(root);
+ while(! stack.isEmpty()) {
+ while(current.left != null) {
+ current = current.left;
+ stack.push(current);
+ }
+ current = stack.pop();
+ visit(current.value);
+ if(current.right != null) {
+ current = current.right;
+ stack.push(current);
+ }
+ }
+ }
+
+ public void traversePreOrderWithoutRecursion() {
+ Stack stack = new Stack();
+ Node current = root;
+ stack.push(root);
+ while(! stack.isEmpty()) {
+ current = stack.pop();
+ visit(current.value);
+
+ if(current.right != null)
+ stack.push(current.right);
+
+ if(current.left != null)
+ stack.push(current.left);
+ }
+ }
+
+ public void traversePostOrderWithoutRecursion() {
+ Stack stack = new Stack();
+ Node prev = root;
+ Node current = root;
+ stack.push(root);
+
+ while (!stack.isEmpty()) {
+ current = stack.peek();
+ boolean hasChild = (current.left != null || current.right != null);
+ boolean isPrevLastChild = (prev == current.right || (prev == current.left && current.right == null));
+
+ if (!hasChild || isPrevLastChild) {
+ current = stack.pop();
+ visit(current.value);
+ prev = current;
+ } else {
+ if (current.right != null) {
+ stack.push(current.right);
+ }
+ if (current.left != null) {
+ stack.push(current.left);
+ }
+ }
+ }
+ }
+
+ private void visit(int value) {
+ System.out.print(" " + value);
+ }
+
+ class Node {
+ int value;
+ Node left;
+ Node right;
+
+ Node(int value) {
+ this.value = value;
+ right = null;
+ left = null;
+ }
+ }
+}
\ No newline at end of file
diff --git a/TicTacToe - MinMax/TicTacToe - MinMax.iml b/TicTacToe - MinMax/TicTacToe - MinMax.iml
new file mode 100644
index 0000000..64f7451
--- /dev/null
+++ b/TicTacToe - MinMax/TicTacToe - MinMax.iml
@@ -0,0 +1,12 @@
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/TicTacToe - MinMax/src/Board.java b/TicTacToe - MinMax/src/Board.java
new file mode 100644
index 0000000..694f605
--- /dev/null
+++ b/TicTacToe - MinMax/src/Board.java
@@ -0,0 +1,147 @@
+import javax.swing.*;
+import java.awt.*;
+import java.awt.event.ActionEvent;
+import java.awt.event.ActionListener;
+import java.awt.event.MouseAdapter;
+import java.awt.event.MouseEvent;
+import java.util.Arrays;
+
+public class Board extends JPanel implements ActionListener {
+
+ private final int B_WIDTH = 900;
+ private final int B_HEIGHT = 900;
+ private final int TILE_X = 300;
+ private final int TILE_Y = 300;
+ private final int DELAY = 50;
+
+ private boolean ended = false;
+
+ private boolean gameWon = false;
+ private boolean initialized = false;
+
+ int[] oldPlayfield;
+
+ private Timer timer;
+ private Game game;
+ private Painter painter;
+
+ public Board(){
+ initBoard();
+ }
+
+ private void initBoard(){
+ painter = new Painter(B_WIDTH,B_HEIGHT);
+
+ addMouseListener(new MouseAdapter() {
+ @Override
+ public void mouseClicked(MouseEvent e) {
+ super.mouseClicked(e);
+ int column = e.getX()/TILE_X;
+ int row = e.getY()/TILE_Y;
+ game.place(column * 3 + row, 1);
+ }
+ });
+
+ setBackground(Color.BLACK);
+ setFocusable(true);
+ setPreferredSize(new Dimension(B_WIDTH,B_HEIGHT));
+
+ initGame();
+ }
+
+ private void initGame(){
+ game = new Game();
+ oldPlayfield = game.getPlayfield().clone();
+ timer = new Timer(DELAY, this);
+ timer.start();
+ }
+
+ @Override
+ protected void paintComponent(Graphics g) {
+ super.paintComponent(g);
+ painter.paintGrid(g);
+ updateBoard(g);
+ }
+
+ private void updateBoard(Graphics g){
+ int actions = 0;
+ for (int column = 0; column < 3; column++) {
+ for (int row = 0; row < 3; row++) {
+ if (game.getPlayfield()[actions] == 1) {
+ painter.drawX(g, column, row);
+ } else if (game.getPlayfield()[actions] == -1) {
+ painter.drawO(g, column, row);
+ }
+ actions++;
+ }
+ }
+ if (ended) {
+ painter.paintWinnerLine(g);
+ }
+ }
+
+ public void resetBoard(){
+ for (int i = 0; i < game.getPlayfield().length; i++){
+ game.setPlayfield(i, 0);
+ }
+ timer.start();
+ oldPlayfield = game.getPlayfield().clone();
+ game.setTurnTaken(false);
+ ended = false;
+ repaint();
+ }
+
+ public void setWinningLine(){
+ painter.setWinningX1(game.getWinningX1());
+ painter.setWinningY1(game.getWinningY1());
+ painter.setWinningX2(game.getWinningX2());
+ painter.setWinningY2(game.getWinningY2());
+ }
+
+ //game controlling method
+ @Override
+ public void actionPerformed(ActionEvent e) {
+ Thread actionThread = new Thread(){
+ @Override
+ public void run() {
+ //check if game state evaluation needs to be done
+ if (isChanged(oldPlayfield)) {
+ gameWon = game.checkWin();
+ //repaint board if not won
+ if (!gameWon) {
+ repaint();
+ oldPlayfield = game.getPlayfield().clone();
+ }
+ //stop timer if game won
+ else if (gameWon || game.emptyTiles() == 0) {
+ ended = true;
+ setWinningLine();
+ repaint();
+ timer.stop();
+ try {
+ Thread.sleep(1000);
+ int n = JOptionPane.showConfirmDialog(null, "Do you want to play again?");
+ if (n == 0){
+ resetBoard();
+ } else {
+ System.exit(0);
+ }
+ } catch (InterruptedException interruptedException) {
+ interruptedException.printStackTrace();
+ }
+ }
+ }
+ //check if computer needs to take a turn
+ if (game.isTurnTaken()){
+ game.setTurnTaken(false);
+ game.computersTurn();
+ }
+ }
+ };
+ actionThread.start();
+ }
+
+ private boolean isChanged(int[] playfield){
+ return !Arrays.equals(game.getPlayfield(), playfield);
+ }
+}
diff --git a/TicTacToe - MinMax/src/Executor.java b/TicTacToe - MinMax/src/Executor.java
new file mode 100644
index 0000000..881fc69
--- /dev/null
+++ b/TicTacToe - MinMax/src/Executor.java
@@ -0,0 +1,26 @@
+import javax.swing.*;
+
+public class Executor extends JFrame {
+ public Executor(){
+ initUI();
+ }
+
+ private void initUI(){
+ Board board = new Board();
+ setTitle("TicTacToe - MinMax");
+ add(board);
+ pack();
+ setDefaultCloseOperation(EXIT_ON_CLOSE);
+ setLocationRelativeTo(null);
+ }
+
+ public static void main(String[] args) {
+ SwingUtilities.invokeLater(new Runnable() {
+ @Override
+ public void run() {
+ Executor exc = new Executor();
+ exc.setVisible(true);
+ }
+ });
+ }
+}
diff --git a/TicTacToe - MinMax/src/Game.java b/TicTacToe - MinMax/src/Game.java
new file mode 100644
index 0000000..842a541
--- /dev/null
+++ b/TicTacToe - MinMax/src/Game.java
@@ -0,0 +1,116 @@
+import javax.swing.*;
+
+public class Game {
+
+ private int[] playfield;
+ private boolean turnTaken = false;
+ private int winningX1,winningY1,winningX2,winningY2;
+
+ public Game(){
+ playfield = new int[9];
+ }
+
+ public void place(int position, int player){
+ if (playfield[position] == 0){
+ playfield[position] = player;
+ if (player == 1) {
+ turnTaken = true;
+ }
+ } else {
+ JOptionPane.showInternalMessageDialog(null,"Tile is already taken");
+ }
+ }
+
+ public void computersTurn(){
+ boolean isPlaced = false;
+ try {
+ Thread.sleep(750);
+ } catch (InterruptedException e) {
+ e.printStackTrace();
+ }
+ while(!isPlaced){
+ int random = (int) (Math.random() * 9);
+ // if field is free
+ if (playfield[random] == 0) {
+ place(random, -1);
+ isPlaced = true;
+ }
+ }
+ }
+
+ public boolean checkWin() {
+ //only check if winning is possible
+ if (emptyTiles() < 5) {
+ for (int i = 0; i < 3; i++) {
+ //horizontal
+ if ((playfield[i] == playfield[i + 3] && playfield[i] != 0) && (playfield[i] == playfield[i + 6])) {
+ winningX1 = 75;
+ winningX2 = 825;
+ winningY1 = winningY2 = i * 300 + 150;
+ return true;
+ }
+ //vertical
+ else if ((playfield[i * 3] == playfield[i * 3 + 1] && playfield[i * 3] != 0) && (playfield[i * 3] == playfield[i * 3 + 2])) {
+ winningY1 = 75;
+ winningY2 = 825;
+ winningX1 = winningX2 = i * 300 + 150;
+ return true;
+ }
+ }
+ //diagonal
+ if ((playfield[2] == playfield[4] && playfield[2] != 0) && (playfield[2] == playfield[6])){
+ winningX2 = winningY1 = 75;
+ winningX1 = winningY2 = 825;
+ return true;
+ } else if ((playfield[0] == playfield[4] && playfield[0] != 0) && (playfield[0] == playfield[8])){
+ winningX1 = winningY1 = 75;
+ winningX2 = winningY2 = 825;
+ return true;
+ }
+ }
+ return false;
+ }
+
+ public int emptyTiles(){
+ int n = 9;
+ for (int i = 0; i < playfield.length; i++){
+ if (playfield[i] != 0){
+ n -= 1;
+ }
+ }
+ System.out.println(n);
+ return n;
+ }
+
+ public boolean isTurnTaken() {
+ return turnTaken;
+ }
+
+ public void setTurnTaken(boolean turnTaken) {
+ this.turnTaken = turnTaken;
+ }
+
+ public void setPlayfield(int position, int value) {
+ playfield[position] = value;
+ }
+
+ public int[] getPlayfield() {
+ return playfield;
+ }
+
+ public int getWinningX1() {
+ return winningX1;
+ }
+
+ public int getWinningX2() {
+ return winningX2;
+ }
+
+ public int getWinningY1() {
+ return winningY1;
+ }
+
+ public int getWinningY2() {
+ return winningY2;
+ }
+}
diff --git a/TicTacToe - MinMax/src/META-INF/MANIFEST.MF b/TicTacToe - MinMax/src/META-INF/MANIFEST.MF
new file mode 100644
index 0000000..357fd3e
--- /dev/null
+++ b/TicTacToe - MinMax/src/META-INF/MANIFEST.MF
@@ -0,0 +1,3 @@
+Manifest-Version: 1.0
+Main-Class: Executor
+
diff --git a/TicTacToe - MinMax/src/Painter.java b/TicTacToe - MinMax/src/Painter.java
new file mode 100644
index 0000000..6bd39f5
--- /dev/null
+++ b/TicTacToe - MinMax/src/Painter.java
@@ -0,0 +1,73 @@
+import java.awt.*;
+
+public class Painter {
+
+ private final int TILE_X;
+ private final int TILE_Y;
+
+ private int winningX1, winningY1, winningX2, winningY2;
+
+ public Painter(int boardWidth, int boardHeight){
+ TILE_X = boardWidth/3;
+ TILE_Y = boardHeight/3;
+ }
+
+ public void drawX(Graphics g, int column, int row) {
+ Graphics2D g2d = (Graphics2D) g;
+
+ int nextColumn = column + 1;
+ int nextRow = row + 1;
+ int x1 = column * TILE_X + 25;
+ int x2 = nextColumn * TILE_Y - 25;
+ int y1 = row * TILE_X + 25;
+ int y2 = nextRow * TILE_Y - 25;
+
+ g2d.setColor(Color.WHITE);
+ g2d.setStroke(new BasicStroke(5));
+ g2d.drawLine(x1, y1, x2, y2);
+ g2d.drawLine(x1, y2, x2, y1);
+ }
+
+ public void drawO(Graphics g, int column, int row){
+ int x = column * TILE_X + 25;
+ int y = row * TILE_Y + 25;
+ g.drawOval(x,y,250,250);
+ }
+
+ public void paintGrid(Graphics g){
+ Graphics2D g2d = (Graphics2D)g;
+ g2d.setColor(Color.WHITE);
+ g2d.setStroke(new BasicStroke(10));
+ //horizontal
+ for (int i = 1; i < 3; i++) {
+ g2d.drawLine(0, TILE_Y*i, TILE_X*3, TILE_Y*i);
+ }
+ //vertical
+ for (int i = 1; i < 3; i++){
+ g2d.drawLine(TILE_X*i, 0, TILE_X*i, TILE_Y*3);
+ }
+ }
+
+ public void paintWinnerLine(Graphics g){
+ Graphics2D g2d = (Graphics2D) g;
+ g2d.setColor(Color.RED);
+ g2d.setStroke(new BasicStroke(40));
+ g2d.drawLine(winningX1, winningY1, winningX2, winningY2);
+ }
+
+ public void setWinningX1(int winningX1) {
+ this.winningX1 = winningX1;
+ }
+
+ public void setWinningX2(int winningX2) {
+ this.winningX2 = winningX2;
+ }
+
+ public void setWinningY1(int winningY1) {
+ this.winningY1 = winningY1;
+ }
+
+ public void setWinningY2(int winningY2) {
+ this.winningY2 = winningY2;
+ }
+}
diff --git a/TicTacToe - MinMax/src/minmax_pseudo.txt b/TicTacToe - MinMax/src/minmax_pseudo.txt
new file mode 100644
index 0000000..f2ec103
--- /dev/null
+++ b/TicTacToe - MinMax/src/minmax_pseudo.txt
@@ -0,0 +1,9 @@
+Variables:
+player, board, search_depth
+
+Data_structure:
+BinaryTree
+
+Loops:
+recursion
+ for-loop
diff --git a/TicTacToe_MinMax/src/Game.java b/TicTacToe_MinMax/src/Game.java
deleted file mode 100644
index 42d8361..0000000
--- a/TicTacToe_MinMax/src/Game.java
+++ /dev/null
@@ -1,41 +0,0 @@
-import javax.swing.*;
-
-public class Game {
-
- public void place(int player, int position, int[] playfield){
- if (playfield[position] == -1){
- playfield[position] = player;
- } else {
- JOptionPane.showConfirmDialog(null,"Tile is already taken");
- }
- }
-
- private boolean checkWin(int[] playfield){
- for (int i = 0; i < 3; i++){
- if ((playfield[i] == playfield[i+3]) && (playfield[i] == playfield[i+6])){
- System.out.println("vertical");
- return true;
- } else if ((playfield[i*3] == playfield[i*3+1]) && (playfield[i*3] == playfield[i*3+2])){
- System.out.println("horizontal");
- return true;
- }
- }
- return (playfield[2] == playfield[4]) && (playfield[2] == playfield[6]) || (playfield[0] == playfield[4]) && (playfield[0] == playfield[8]);
- }
-
-
- public static void main(String[] args) {
- Game game = new Game();
- Render render = new Render();
-
- int[] playfield = {1,0,-1,1,1,0,-1,0,1};
-
- SwingUtilities.invokeLater(new Runnable() {
- public void run() {
- render.createUI(playfield);
- }
- });
-
- System.out.println(game.checkWin(playfield));
- }
-}
diff --git a/TicTacToe_MinMax/src/Render.java b/TicTacToe_MinMax/src/Render.java
deleted file mode 100644
index 6a17a7f..0000000
--- a/TicTacToe_MinMax/src/Render.java
+++ /dev/null
@@ -1,135 +0,0 @@
-import javax.swing.*;
-import java.awt.*;
-import java.awt.geom.AffineTransform;
-
-public class Render {
-
- public static void createUI(int[] playfield){
- JFrame f = new JFrame("Swing Paint Demo");
- MyPanel myPanel = new MyPanel(playfield);
- f.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
- f.add(myPanel);
- f.pack();
- f.setLocationRelativeTo(null);
- f.setVisible(true);
- }
-
-}
-
-class MyPanel extends JPanel {
- Grid grid;
- GameCharacters gameCharacters;
-
- public MyPanel() {
- setBorder(BorderFactory.createLineBorder(Color.BLACK));
- grid = new Grid();
- }
-
- public MyPanel(int[] playfield){
- setBorder(BorderFactory.createLineBorder(Color.BLACK));
- grid = new Grid();
- gameCharacters = new GameCharacters(playfield);
- }
-
- public Dimension getPreferredSize() {
- return new Dimension(900,900);
- }
-
- public void paintComponent(Graphics g) {
- super.paintComponent(g);
- grid.paintGrid(g);
- gameCharacters.paintGameCharacters(g);
- }
-}
-
-class Grid{
- private final int TILE_X = 300;
- private final int TILE_Y = 300;
-
- public void paintGrid(Graphics g){
- g.setColor(Color.BLACK);
- //horizontal
- for (int i = 1; i < 3; i++) {
- Graphics2D g2d = (Graphics2D)g;
- g2d.setStroke(new BasicStroke(5));
- g2d.drawLine(0, TILE_Y*i, TILE_X*3, TILE_Y*i);
- }
- //vertical
- for (int i = 1; i < 3; i++){
- Graphics2D g2d = (Graphics2D)g;
- g2d.setStroke(new BasicStroke(5));
- g2d.drawLine(TILE_X*i, 0, TILE_X*i, TILE_Y*3);
- }
- }
-}
-
-class GameCharacters {
- CharacterX characterX = new CharacterX();
- CharacterO characterO = new CharacterO();
-
- private final int TILE_X = 300;
- private final int TILE_Y = 300;
-
- int[] playfield;
-
- public GameCharacters(int[] playfield) {
- this.playfield = playfield;
- }
-
- public void paintGameCharacters(Graphics g) {
- int actions = 0;
- for (int column = 0; column < 3; column++) {
- for (int row = 0; row < 3; row++) {
- if (playfield[actions] == 1) {
- characterX.setX(TILE_X * row);
- characterX.setY(TILE_Y * column);
- characterX.paintX(g);
- } else if (playfield[actions] == -1) {
- characterO.setX(TILE_X * row);
- characterO.setY(TILE_Y * column);
- characterO.paintO(g);
- }
- actions++;
- }
- }
- }
-
- class CharacterX {
- private int x;
- private int y;
-
- public void paintX(Graphics g) {
- Graphics2D g2d = (Graphics2D)g;
- g2d.setStroke(new BasicStroke(10));
- g2d.drawLine(x+25, y+25, x+275, y+275);
- g2d.drawLine(x+25, y +275, x+275, y+25);
- }
-
- public void setX(int x) {
- this.x = x;
- }
-
- public void setY(int y) {
- this.y = y;
- }
- }
-
- class CharacterO {
- private int x;
- private int y;
-
- public void paintO(Graphics g) {
- Graphics2D g2d = (Graphics2D)g;
- g2d.setStroke(new BasicStroke(10));
- g2d.drawOval(x + 25, y + 25, 250, 250);
- }
-
- public void setX(int x) {
- this.x = x;
- }
-
- public void setY(int y) {
- this.y = y;
- }
- }
-}
diff --git a/out/artifacts/TicTacToe___MinMax_jar/TicTacToe - MinMax.jar b/out/artifacts/TicTacToe___MinMax_jar/TicTacToe - MinMax.jar
new file mode 100755
index 0000000..72a263b
Binary files /dev/null and b/out/artifacts/TicTacToe___MinMax_jar/TicTacToe - MinMax.jar differ
diff --git a/out/production/ATM-Machine/ATM-Machine.iml b/out/production/ATM-Machine/ATM-Machine.iml
new file mode 100644
index 0000000..b107a2d
--- /dev/null
+++ b/out/production/ATM-Machine/ATM-Machine.iml
@@ -0,0 +1,11 @@
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/out/production/ATM-Machine/Accounts.class b/out/production/ATM-Machine/Accounts.class
index 67de895..97cf119 100644
Binary files a/out/production/ATM-Machine/Accounts.class and b/out/production/ATM-Machine/Accounts.class differ
diff --git a/out/production/ATM-Machine/Operator.class b/out/production/ATM-Machine/Operator.class
deleted file mode 100644
index a4b351f..0000000
Binary files a/out/production/ATM-Machine/Operator.class and /dev/null differ
diff --git a/out/production/ATM-Machine/META-INF/MANIFEST.MF b/out/production/ATM-Machine/src/META-INF/MANIFEST.MF
similarity index 100%
rename from out/production/ATM-Machine/META-INF/MANIFEST.MF
rename to out/production/ATM-Machine/src/META-INF/MANIFEST.MF
diff --git a/out/production/ATM-Machine/src/NumberPicker.class b/out/production/ATM-Machine/src/NumberPicker.class
index aa09590..053f239 100644
Binary files a/out/production/ATM-Machine/src/NumberPicker.class and b/out/production/ATM-Machine/src/NumberPicker.class differ
diff --git a/out/production/ATM-Machine/src/Operator.class b/out/production/ATM-Machine/src/Operator.class
new file mode 100644
index 0000000..906beae
Binary files /dev/null and b/out/production/ATM-Machine/src/Operator.class differ
diff --git a/out/production/BruitForce/com/BiteCoding/github/Decoder.class b/out/production/BruitForce/com/BiteCoding/github/Decoder.class
index 14ff2d6..af31f6a 100644
Binary files a/out/production/BruitForce/com/BiteCoding/github/Decoder.class and b/out/production/BruitForce/com/BiteCoding/github/Decoder.class differ
diff --git a/out/production/BruitForce/com/BiteCoding/github/Simulation.class b/out/production/BruitForce/com/BiteCoding/github/Simulation.class
index 1a1c028..fffb915 100644
Binary files a/out/production/BruitForce/com/BiteCoding/github/Simulation.class and b/out/production/BruitForce/com/BiteCoding/github/Simulation.class differ
diff --git a/out/production/CodingChallanges/arrays/PoppingBlocks.class b/out/production/CodingChallanges/arrays/PoppingBlocks.class
index e8c6f02..48f9efa 100644
Binary files a/out/production/CodingChallanges/arrays/PoppingBlocks.class and b/out/production/CodingChallanges/arrays/PoppingBlocks.class differ
diff --git a/out/production/CodingChallanges/geometry/PentagonalNumber.class b/out/production/CodingChallanges/geometry/PentagonalNumber.class
index b820f82..1cdc6e7 100644
Binary files a/out/production/CodingChallanges/geometry/PentagonalNumber.class and b/out/production/CodingChallanges/geometry/PentagonalNumber.class differ
diff --git a/out/production/CodingChallanges/geometry/makeGrid.class b/out/production/CodingChallanges/geometry/makeGrid.class
index 69b329f..751e38e 100644
Binary files a/out/production/CodingChallanges/geometry/makeGrid.class and b/out/production/CodingChallanges/geometry/makeGrid.class differ
diff --git a/out/production/CodingChallanges/numbers/CarryingTheDigits.class b/out/production/CodingChallanges/numbers/CarryingTheDigits.class
index 1070800..44b1ade 100644
Binary files a/out/production/CodingChallanges/numbers/CarryingTheDigits.class and b/out/production/CodingChallanges/numbers/CarryingTheDigits.class differ
diff --git a/out/production/CodingChallanges/numbers/FindPrimorial.class b/out/production/CodingChallanges/numbers/FindPrimorial.class
index 44046ba..e1e6f96 100644
Binary files a/out/production/CodingChallanges/numbers/FindPrimorial.class and b/out/production/CodingChallanges/numbers/FindPrimorial.class differ
diff --git a/out/production/CodingChallanges/numbers/HowManyPrimes_NOT_SOLVED.class b/out/production/CodingChallanges/numbers/HowManyPrimes_NOT_SOLVED.class
index ea0c782..d9bc2f6 100644
Binary files a/out/production/CodingChallanges/numbers/HowManyPrimes_NOT_SOLVED.class and b/out/production/CodingChallanges/numbers/HowManyPrimes_NOT_SOLVED.class differ
diff --git a/out/production/CodingChallanges/numbers/MaxFirstNum.class b/out/production/CodingChallanges/numbers/MaxFirstNum.class
index 9c01ddc..f45ce43 100644
Binary files a/out/production/CodingChallanges/numbers/MaxFirstNum.class and b/out/production/CodingChallanges/numbers/MaxFirstNum.class differ
diff --git a/out/production/CodingChallanges/numbers/SimplifyFractions.class b/out/production/CodingChallanges/numbers/SimplifyFractions.class
index 59361ce..c7277f9 100644
Binary files a/out/production/CodingChallanges/numbers/SimplifyFractions.class and b/out/production/CodingChallanges/numbers/SimplifyFractions.class differ
diff --git a/out/production/CodingChallanges/numbers/ValidateCreditCard.class b/out/production/CodingChallanges/numbers/ValidateCreditCard.class
index 0b29a76..9fa4cce 100644
Binary files a/out/production/CodingChallanges/numbers/ValidateCreditCard.class and b/out/production/CodingChallanges/numbers/ValidateCreditCard.class differ
diff --git a/out/production/CodingChallanges/strings/CharacterMapping.class b/out/production/CodingChallanges/strings/CharacterMapping.class
index 0af5076..54b7c13 100644
Binary files a/out/production/CodingChallanges/strings/CharacterMapping.class and b/out/production/CodingChallanges/strings/CharacterMapping.class differ
diff --git a/out/production/CodingChallanges/strings/DistanceToNearestVowel.class b/out/production/CodingChallanges/strings/DistanceToNearestVowel.class
index ceeb142..1f9b9d1 100644
Binary files a/out/production/CodingChallanges/strings/DistanceToNearestVowel.class and b/out/production/CodingChallanges/strings/DistanceToNearestVowel.class differ
diff --git a/out/production/CodingChallanges/strings/FilterStringArray.class b/out/production/CodingChallanges/strings/FilterStringArray.class
index 0653274..60c8a54 100644
Binary files a/out/production/CodingChallanges/strings/FilterStringArray.class and b/out/production/CodingChallanges/strings/FilterStringArray.class differ
diff --git a/out/production/CodingChallanges/strings/FiscalCode.class b/out/production/CodingChallanges/strings/FiscalCode.class
index e90d2f6..5f6c5b5 100644
Binary files a/out/production/CodingChallanges/strings/FiscalCode.class and b/out/production/CodingChallanges/strings/FiscalCode.class differ
diff --git a/out/production/CodingChallanges/strings/LongestAlternatingSubstring.class b/out/production/CodingChallanges/strings/LongestAlternatingSubstring.class
index 1772484..89dc4fb 100644
Binary files a/out/production/CodingChallanges/strings/LongestAlternatingSubstring.class and b/out/production/CodingChallanges/strings/LongestAlternatingSubstring.class differ
diff --git a/out/production/CodingChallanges/strings/SmoothSentences.class b/out/production/CodingChallanges/strings/SmoothSentences.class
index 60af9ea..e9c9c77 100644
Binary files a/out/production/CodingChallanges/strings/SmoothSentences.class and b/out/production/CodingChallanges/strings/SmoothSentences.class differ
diff --git a/out/production/CodingChallanges/strings/WordChain.class b/out/production/CodingChallanges/strings/WordChain.class
index 5d7349a..1e66489 100644
Binary files a/out/production/CodingChallanges/strings/WordChain.class and b/out/production/CodingChallanges/strings/WordChain.class differ
diff --git a/out/production/CodingChallanges/tests/FiscalCodeTest.class b/out/production/CodingChallanges/tests/FiscalCodeTest.class
index 2a2543e..83bb4e3 100644
Binary files a/out/production/CodingChallanges/tests/FiscalCodeTest.class and b/out/production/CodingChallanges/tests/FiscalCodeTest.class differ
diff --git a/out/production/CodingChallanges/tests/PigLatinTranslationTest.class b/out/production/CodingChallanges/tests/PigLatinTranslationTest.class
index 826309d..93367f8 100644
Binary files a/out/production/CodingChallanges/tests/PigLatinTranslationTest.class and b/out/production/CodingChallanges/tests/PigLatinTranslationTest.class differ
diff --git a/out/production/CodingChallanges/tests/ValidateCreditCardTest.class b/out/production/CodingChallanges/tests/ValidateCreditCardTest.class
index 9f810d1..8c62183 100644
Binary files a/out/production/CodingChallanges/tests/ValidateCreditCardTest.class and b/out/production/CodingChallanges/tests/ValidateCreditCardTest.class differ
diff --git a/out/production/CodingChallanges/tests/WordChainTest.class b/out/production/CodingChallanges/tests/WordChainTest.class
index b85d17c..c2d1e5c 100644
Binary files a/out/production/CodingChallanges/tests/WordChainTest.class and b/out/production/CodingChallanges/tests/WordChainTest.class differ
diff --git a/out/production/CodingChallanges/translation_encryption/EdabitEncription.class b/out/production/CodingChallanges/translation_encryption/EdabitEncription.class
index 71bc5e8..3fbedf3 100644
Binary files a/out/production/CodingChallanges/translation_encryption/EdabitEncription.class and b/out/production/CodingChallanges/translation_encryption/EdabitEncription.class differ
diff --git a/out/production/CodingChallanges/translation_encryption/KaracasEncryption.class b/out/production/CodingChallanges/translation_encryption/KaracasEncryption.class
index 78c3185..7f6e7b8 100644
Binary files a/out/production/CodingChallanges/translation_encryption/KaracasEncryption.class and b/out/production/CodingChallanges/translation_encryption/KaracasEncryption.class differ
diff --git a/out/production/CodingChallanges/translation_encryption/PigLatinTranslation.class b/out/production/CodingChallanges/translation_encryption/PigLatinTranslation.class
index 8801cbb..cccbf0e 100644
Binary files a/out/production/CodingChallanges/translation_encryption/PigLatinTranslation.class and b/out/production/CodingChallanges/translation_encryption/PigLatinTranslation.class differ
diff --git a/out/production/DemoProjects/META-INF/DemoProjects.kotlin_module b/out/production/DemoProjects/META-INF/DemoProjects.kotlin_module
deleted file mode 100644
index a49347a..0000000
Binary files a/out/production/DemoProjects/META-INF/DemoProjects.kotlin_module and /dev/null differ
diff --git a/out/production/DemoProjects/animation/swingTimer/Board.class b/out/production/DemoProjects/animation/swingTimer/Board.class
new file mode 100644
index 0000000..7f921f4
Binary files /dev/null and b/out/production/DemoProjects/animation/swingTimer/Board.class differ
diff --git a/out/production/DemoProjects/animation/swingTimer/SwingTimer.class b/out/production/DemoProjects/animation/swingTimer/SwingTimer.class
new file mode 100644
index 0000000..1f74241
Binary files /dev/null and b/out/production/DemoProjects/animation/swingTimer/SwingTimer.class differ
diff --git a/out/production/DemoProjects/animation/thread/Board.class b/out/production/DemoProjects/animation/thread/Board.class
new file mode 100644
index 0000000..149bf85
Binary files /dev/null and b/out/production/DemoProjects/animation/thread/Board.class differ
diff --git a/out/production/DemoProjects/animation/thread/ThreadAnimation.class b/out/production/DemoProjects/animation/thread/ThreadAnimation.class
new file mode 100644
index 0000000..9e05b19
Binary files /dev/null and b/out/production/DemoProjects/animation/thread/ThreadAnimation.class differ
diff --git a/out/production/DemoProjects/animation/utilityTimer/Board$1.class b/out/production/DemoProjects/animation/utilityTimer/Board$1.class
new file mode 100644
index 0000000..881f123
Binary files /dev/null and b/out/production/DemoProjects/animation/utilityTimer/Board$1.class differ
diff --git a/out/production/DemoProjects/animation/utilityTimer/Board$ScheduleTask.class b/out/production/DemoProjects/animation/utilityTimer/Board$ScheduleTask.class
new file mode 100644
index 0000000..f83368e
Binary files /dev/null and b/out/production/DemoProjects/animation/utilityTimer/Board$ScheduleTask.class differ
diff --git a/out/production/DemoProjects/animation/utilityTimer/Board.class b/out/production/DemoProjects/animation/utilityTimer/Board.class
new file mode 100644
index 0000000..9c0d01d
Binary files /dev/null and b/out/production/DemoProjects/animation/utilityTimer/Board.class differ
diff --git a/out/production/DemoProjects/animation/utilityTimer/UtilityTimer.class b/out/production/DemoProjects/animation/utilityTimer/UtilityTimer.class
new file mode 100644
index 0000000..22e8e26
Binary files /dev/null and b/out/production/DemoProjects/animation/utilityTimer/UtilityTimer.class differ
diff --git a/out/production/DemoProjects/painting/MyPanel1.class b/out/production/DemoProjects/painting/MyPanel1.class
deleted file mode 100644
index 6c4fdd4..0000000
Binary files a/out/production/DemoProjects/painting/MyPanel1.class and /dev/null differ
diff --git a/out/production/DemoProjects/painting/MyPanel2$1.class b/out/production/DemoProjects/painting/MyPanel2$1.class
deleted file mode 100644
index 0736679..0000000
Binary files a/out/production/DemoProjects/painting/MyPanel2$1.class and /dev/null differ
diff --git a/out/production/DemoProjects/painting/MyPanel2$2.class b/out/production/DemoProjects/painting/MyPanel2$2.class
deleted file mode 100644
index 04b4fbf..0000000
Binary files a/out/production/DemoProjects/painting/MyPanel2$2.class and /dev/null differ
diff --git a/out/production/DemoProjects/painting/MyPanel2.class b/out/production/DemoProjects/painting/MyPanel2.class
deleted file mode 100644
index 25a3e92..0000000
Binary files a/out/production/DemoProjects/painting/MyPanel2.class and /dev/null differ
diff --git a/out/production/DemoProjects/painting/MyPanel3$1.class b/out/production/DemoProjects/painting/MyPanel3$1.class
deleted file mode 100644
index 5a25783..0000000
Binary files a/out/production/DemoProjects/painting/MyPanel3$1.class and /dev/null differ
diff --git a/out/production/DemoProjects/painting/MyPanel3$2.class b/out/production/DemoProjects/painting/MyPanel3$2.class
deleted file mode 100644
index 48de853..0000000
Binary files a/out/production/DemoProjects/painting/MyPanel3$2.class and /dev/null differ
diff --git a/out/production/DemoProjects/painting/MyPanel3.class b/out/production/DemoProjects/painting/MyPanel3.class
deleted file mode 100644
index 7549ca4..0000000
Binary files a/out/production/DemoProjects/painting/MyPanel3.class and /dev/null differ
diff --git a/out/production/DemoProjects/painting/RedSquare.class b/out/production/DemoProjects/painting/RedSquare.class
deleted file mode 100644
index ec99768..0000000
Binary files a/out/production/DemoProjects/painting/RedSquare.class and /dev/null differ
diff --git a/out/production/DemoProjects/painting/SwingPaintDemo/MyPanel1.class b/out/production/DemoProjects/painting/SwingPaintDemo/MyPanel1.class
new file mode 100644
index 0000000..6ec1bcc
Binary files /dev/null and b/out/production/DemoProjects/painting/SwingPaintDemo/MyPanel1.class differ
diff --git a/out/production/DemoProjects/painting/SwingPaintDemo/MyPanel2$1.class b/out/production/DemoProjects/painting/SwingPaintDemo/MyPanel2$1.class
new file mode 100644
index 0000000..3f0ed8a
Binary files /dev/null and b/out/production/DemoProjects/painting/SwingPaintDemo/MyPanel2$1.class differ
diff --git a/out/production/DemoProjects/painting/SwingPaintDemo/MyPanel2$2.class b/out/production/DemoProjects/painting/SwingPaintDemo/MyPanel2$2.class
new file mode 100644
index 0000000..60e7ea3
Binary files /dev/null and b/out/production/DemoProjects/painting/SwingPaintDemo/MyPanel2$2.class differ
diff --git a/out/production/DemoProjects/painting/SwingPaintDemo/MyPanel2.class b/out/production/DemoProjects/painting/SwingPaintDemo/MyPanel2.class
new file mode 100644
index 0000000..0caf08b
Binary files /dev/null and b/out/production/DemoProjects/painting/SwingPaintDemo/MyPanel2.class differ
diff --git a/out/production/DemoProjects/painting/SwingPaintDemo/MyPanel3$1.class b/out/production/DemoProjects/painting/SwingPaintDemo/MyPanel3$1.class
new file mode 100644
index 0000000..a0e0c95
Binary files /dev/null and b/out/production/DemoProjects/painting/SwingPaintDemo/MyPanel3$1.class differ
diff --git a/out/production/DemoProjects/painting/SwingPaintDemo/MyPanel3$2.class b/out/production/DemoProjects/painting/SwingPaintDemo/MyPanel3$2.class
new file mode 100644
index 0000000..78b5e26
Binary files /dev/null and b/out/production/DemoProjects/painting/SwingPaintDemo/MyPanel3$2.class differ
diff --git a/out/production/DemoProjects/painting/SwingPaintDemo/MyPanel3.class b/out/production/DemoProjects/painting/SwingPaintDemo/MyPanel3.class
new file mode 100644
index 0000000..27d14fa
Binary files /dev/null and b/out/production/DemoProjects/painting/SwingPaintDemo/MyPanel3.class differ
diff --git a/out/production/DemoProjects/painting/SwingPaintDemo/RedSquare.class b/out/production/DemoProjects/painting/SwingPaintDemo/RedSquare.class
new file mode 100644
index 0000000..18cb0d6
Binary files /dev/null and b/out/production/DemoProjects/painting/SwingPaintDemo/RedSquare.class differ
diff --git a/out/production/DemoProjects/painting/SwingPaintDemo/SwingPaintDemo1$1.class b/out/production/DemoProjects/painting/SwingPaintDemo/SwingPaintDemo1$1.class
new file mode 100644
index 0000000..178cd9d
Binary files /dev/null and b/out/production/DemoProjects/painting/SwingPaintDemo/SwingPaintDemo1$1.class differ
diff --git a/out/production/DemoProjects/painting/SwingPaintDemo/SwingPaintDemo1.class b/out/production/DemoProjects/painting/SwingPaintDemo/SwingPaintDemo1.class
new file mode 100644
index 0000000..627df60
Binary files /dev/null and b/out/production/DemoProjects/painting/SwingPaintDemo/SwingPaintDemo1.class differ
diff --git a/out/production/DemoProjects/painting/SwingPaintDemo/SwingPaintDemo2$1.class b/out/production/DemoProjects/painting/SwingPaintDemo/SwingPaintDemo2$1.class
new file mode 100644
index 0000000..0cc9d9b
Binary files /dev/null and b/out/production/DemoProjects/painting/SwingPaintDemo/SwingPaintDemo2$1.class differ
diff --git a/out/production/DemoProjects/painting/SwingPaintDemo/SwingPaintDemo2.class b/out/production/DemoProjects/painting/SwingPaintDemo/SwingPaintDemo2.class
new file mode 100644
index 0000000..a3d7369
Binary files /dev/null and b/out/production/DemoProjects/painting/SwingPaintDemo/SwingPaintDemo2.class differ
diff --git a/out/production/DemoProjects/painting/SwingPaintDemo/SwingPaintDemo3$1.class b/out/production/DemoProjects/painting/SwingPaintDemo/SwingPaintDemo3$1.class
new file mode 100644
index 0000000..834b969
Binary files /dev/null and b/out/production/DemoProjects/painting/SwingPaintDemo/SwingPaintDemo3$1.class differ
diff --git a/out/production/DemoProjects/painting/SwingPaintDemo/SwingPaintDemo3.class b/out/production/DemoProjects/painting/SwingPaintDemo/SwingPaintDemo3.class
new file mode 100644
index 0000000..b093fe5
Binary files /dev/null and b/out/production/DemoProjects/painting/SwingPaintDemo/SwingPaintDemo3.class differ
diff --git a/out/production/DemoProjects/painting/SwingPaintDemo/SwingPaintDemo4$1.class b/out/production/DemoProjects/painting/SwingPaintDemo/SwingPaintDemo4$1.class
new file mode 100644
index 0000000..9c8144c
Binary files /dev/null and b/out/production/DemoProjects/painting/SwingPaintDemo/SwingPaintDemo4$1.class differ
diff --git a/out/production/DemoProjects/painting/SwingPaintDemo/SwingPaintDemo4.class b/out/production/DemoProjects/painting/SwingPaintDemo/SwingPaintDemo4.class
new file mode 100644
index 0000000..7c071bc
Binary files /dev/null and b/out/production/DemoProjects/painting/SwingPaintDemo/SwingPaintDemo4.class differ
diff --git a/out/production/DemoProjects/painting/SwingPaintDemo1$1.class b/out/production/DemoProjects/painting/SwingPaintDemo1$1.class
deleted file mode 100644
index 3bb91db..0000000
Binary files a/out/production/DemoProjects/painting/SwingPaintDemo1$1.class and /dev/null differ
diff --git a/out/production/DemoProjects/painting/SwingPaintDemo1.class b/out/production/DemoProjects/painting/SwingPaintDemo1.class
deleted file mode 100644
index c914c81..0000000
Binary files a/out/production/DemoProjects/painting/SwingPaintDemo1.class and /dev/null differ
diff --git a/out/production/DemoProjects/painting/SwingPaintDemo2$1.class b/out/production/DemoProjects/painting/SwingPaintDemo2$1.class
deleted file mode 100644
index d7ec8a6..0000000
Binary files a/out/production/DemoProjects/painting/SwingPaintDemo2$1.class and /dev/null differ
diff --git a/out/production/DemoProjects/painting/SwingPaintDemo2.class b/out/production/DemoProjects/painting/SwingPaintDemo2.class
deleted file mode 100644
index 535a4e2..0000000
Binary files a/out/production/DemoProjects/painting/SwingPaintDemo2.class and /dev/null differ
diff --git a/out/production/DemoProjects/painting/SwingPaintDemo3$1.class b/out/production/DemoProjects/painting/SwingPaintDemo3$1.class
deleted file mode 100644
index 1e6d04b..0000000
Binary files a/out/production/DemoProjects/painting/SwingPaintDemo3$1.class and /dev/null differ
diff --git a/out/production/DemoProjects/painting/SwingPaintDemo3.class b/out/production/DemoProjects/painting/SwingPaintDemo3.class
deleted file mode 100644
index 954c05e..0000000
Binary files a/out/production/DemoProjects/painting/SwingPaintDemo3.class and /dev/null differ
diff --git a/out/production/DemoProjects/painting/SwingPaintDemo4$1.class b/out/production/DemoProjects/painting/SwingPaintDemo4$1.class
deleted file mode 100644
index 3c902d3..0000000
Binary files a/out/production/DemoProjects/painting/SwingPaintDemo4$1.class and /dev/null differ
diff --git a/out/production/DemoProjects/painting/SwingPaintDemo4.class b/out/production/DemoProjects/painting/SwingPaintDemo4.class
deleted file mode 100644
index 479288c..0000000
Binary files a/out/production/DemoProjects/painting/SwingPaintDemo4.class and /dev/null differ
diff --git a/out/production/DemoProjects/painting/donut/Board.class b/out/production/DemoProjects/painting/donut/Board.class
new file mode 100644
index 0000000..c9518b6
Binary files /dev/null and b/out/production/DemoProjects/painting/donut/Board.class differ
diff --git a/out/production/DemoProjects/painting/donut/Donut.class b/out/production/DemoProjects/painting/donut/Donut.class
new file mode 100644
index 0000000..c48b6ea
Binary files /dev/null and b/out/production/DemoProjects/painting/donut/Donut.class differ
diff --git a/out/production/DemoProjects/painting/image/Board.class b/out/production/DemoProjects/painting/image/Board.class
new file mode 100644
index 0000000..ce620a1
Binary files /dev/null and b/out/production/DemoProjects/painting/image/Board.class differ
diff --git a/out/production/DemoProjects/painting/image/Image.class b/out/production/DemoProjects/painting/image/Image.class
new file mode 100644
index 0000000..fa16ce0
Binary files /dev/null and b/out/production/DemoProjects/painting/image/Image.class differ
diff --git a/out/production/DemoProjects/sprites/shootingMissles/Board$1.class b/out/production/DemoProjects/sprites/shootingMissles/Board$1.class
new file mode 100644
index 0000000..8536454
Binary files /dev/null and b/out/production/DemoProjects/sprites/shootingMissles/Board$1.class differ
diff --git a/out/production/DemoProjects/sprites/shootingMissles/Board$TAdapter.class b/out/production/DemoProjects/sprites/shootingMissles/Board$TAdapter.class
new file mode 100644
index 0000000..bf2378a
Binary files /dev/null and b/out/production/DemoProjects/sprites/shootingMissles/Board$TAdapter.class differ
diff --git a/out/production/DemoProjects/sprites/shootingMissles/Board.class b/out/production/DemoProjects/sprites/shootingMissles/Board.class
new file mode 100644
index 0000000..dd9f3f4
Binary files /dev/null and b/out/production/DemoProjects/sprites/shootingMissles/Board.class differ
diff --git a/out/production/DemoProjects/sprites/shootingMissles/Executor.class b/out/production/DemoProjects/sprites/shootingMissles/Executor.class
new file mode 100644
index 0000000..da508aa
Binary files /dev/null and b/out/production/DemoProjects/sprites/shootingMissles/Executor.class differ
diff --git a/out/production/DemoProjects/sprites/shootingMissles/Missile.class b/out/production/DemoProjects/sprites/shootingMissles/Missile.class
new file mode 100644
index 0000000..41ebfdf
Binary files /dev/null and b/out/production/DemoProjects/sprites/shootingMissles/Missile.class differ
diff --git a/out/production/DemoProjects/sprites/shootingMissles/SpaceShip.class b/out/production/DemoProjects/sprites/shootingMissles/SpaceShip.class
new file mode 100644
index 0000000..7964103
Binary files /dev/null and b/out/production/DemoProjects/sprites/shootingMissles/SpaceShip.class differ
diff --git a/out/production/DemoProjects/sprites/shootingMissles/Sprite.class b/out/production/DemoProjects/sprites/shootingMissles/Sprite.class
new file mode 100644
index 0000000..45a1ffa
Binary files /dev/null and b/out/production/DemoProjects/sprites/shootingMissles/Sprite.class differ
diff --git a/out/production/DemoProjects/sprites/spaceship/Board$1.class b/out/production/DemoProjects/sprites/spaceship/Board$1.class
new file mode 100644
index 0000000..a87c7d2
Binary files /dev/null and b/out/production/DemoProjects/sprites/spaceship/Board$1.class differ
diff --git a/out/production/DemoProjects/sprites/spaceship/Board$TAdapter.class b/out/production/DemoProjects/sprites/spaceship/Board$TAdapter.class
new file mode 100644
index 0000000..6496f3d
Binary files /dev/null and b/out/production/DemoProjects/sprites/spaceship/Board$TAdapter.class differ
diff --git a/out/production/DemoProjects/sprites/spaceship/Board.class b/out/production/DemoProjects/sprites/spaceship/Board.class
new file mode 100644
index 0000000..6dc1882
Binary files /dev/null and b/out/production/DemoProjects/sprites/spaceship/Board.class differ
diff --git a/out/production/DemoProjects/sprites/spaceship/MovingSprite.class b/out/production/DemoProjects/sprites/spaceship/MovingSprite.class
new file mode 100644
index 0000000..fcfe2e7
Binary files /dev/null and b/out/production/DemoProjects/sprites/spaceship/MovingSprite.class differ
diff --git a/out/production/DemoProjects/sprites/spaceship/SpaceShip.class b/out/production/DemoProjects/sprites/spaceship/SpaceShip.class
new file mode 100644
index 0000000..d228908
Binary files /dev/null and b/out/production/DemoProjects/sprites/spaceship/SpaceShip.class differ
diff --git a/out/production/Doodles/Template.class b/out/production/Doodles/Template.class
new file mode 100644
index 0000000..c688ca0
Binary files /dev/null and b/out/production/Doodles/Template.class differ
diff --git a/out/production/ImageToText/Keyboard$1.class b/out/production/ImageToText/Keyboard$1.class
index 094806e..ce8a9f2 100644
Binary files a/out/production/ImageToText/Keyboard$1.class and b/out/production/ImageToText/Keyboard$1.class differ
diff --git a/out/production/ImageToText/Keyboard.class b/out/production/ImageToText/Keyboard.class
index 2cc7b36..a367fe0 100644
Binary files a/out/production/ImageToText/Keyboard.class and b/out/production/ImageToText/Keyboard.class differ
diff --git a/out/production/ImageToText/Text.class b/out/production/ImageToText/Text.class
index d702c65..2323183 100644
Binary files a/out/production/ImageToText/Text.class and b/out/production/ImageToText/Text.class differ
diff --git a/out/production/ImageToText/src/Image$1.class b/out/production/ImageToText/src/Image$1.class
deleted file mode 100644
index 120d8a0..0000000
Binary files a/out/production/ImageToText/src/Image$1.class and /dev/null differ
diff --git a/out/production/ImageToText/src/Image.class b/out/production/ImageToText/src/Image.class
deleted file mode 100644
index 859278d..0000000
Binary files a/out/production/ImageToText/src/Image.class and /dev/null differ
diff --git a/out/production/ImageToText/src/Test.class b/out/production/ImageToText/src/Test.class
index ed0d41d..bf577e5 100644
Binary files a/out/production/ImageToText/src/Test.class and b/out/production/ImageToText/src/Test.class differ
diff --git a/out/production/LanguageAnalysis/src/Image$1.class b/out/production/LanguageAnalysis/src/Image$1.class
new file mode 100644
index 0000000..b8d2374
Binary files /dev/null and b/out/production/LanguageAnalysis/src/Image$1.class differ
diff --git a/out/production/LanguageAnalysis/src/Image.class b/out/production/LanguageAnalysis/src/Image.class
new file mode 100644
index 0000000..e9327e3
Binary files /dev/null and b/out/production/LanguageAnalysis/src/Image.class differ
diff --git a/out/production/LanguageAnalysis/src/Marshal.class b/out/production/LanguageAnalysis/src/Marshal.class
index 97ac26f..182012b 100644
Binary files a/out/production/LanguageAnalysis/src/Marshal.class and b/out/production/LanguageAnalysis/src/Marshal.class differ
diff --git a/out/production/LanguageAnalysis/src/test.class b/out/production/LanguageAnalysis/src/test.class
index 5987ab4..3a7ac3d 100644
Binary files a/out/production/LanguageAnalysis/src/test.class and b/out/production/LanguageAnalysis/src/test.class differ
diff --git a/out/production/TOOLS/BinaryTree$Node.class b/out/production/TOOLS/BinaryTree$Node.class
new file mode 100644
index 0000000..2ae747f
Binary files /dev/null and b/out/production/TOOLS/BinaryTree$Node.class differ
diff --git a/out/production/TOOLS/BinaryTree.class b/out/production/TOOLS/BinaryTree.class
new file mode 100644
index 0000000..949ff80
Binary files /dev/null and b/out/production/TOOLS/BinaryTree.class differ
diff --git a/out/production/TicTacToe - MinMax/Board$1.class b/out/production/TicTacToe - MinMax/Board$1.class
new file mode 100644
index 0000000..8e4ef4e
Binary files /dev/null and b/out/production/TicTacToe - MinMax/Board$1.class differ
diff --git a/out/production/TicTacToe - MinMax/Board$2.class b/out/production/TicTacToe - MinMax/Board$2.class
new file mode 100644
index 0000000..866bc55
Binary files /dev/null and b/out/production/TicTacToe - MinMax/Board$2.class differ
diff --git a/out/production/TicTacToe - MinMax/Board.class b/out/production/TicTacToe - MinMax/Board.class
new file mode 100644
index 0000000..57442c0
Binary files /dev/null and b/out/production/TicTacToe - MinMax/Board.class differ
diff --git a/out/production/TicTacToe - MinMax/Executor$1.class b/out/production/TicTacToe - MinMax/Executor$1.class
new file mode 100644
index 0000000..0b1bd9f
Binary files /dev/null and b/out/production/TicTacToe - MinMax/Executor$1.class differ
diff --git a/out/production/TicTacToe - MinMax/Executor.class b/out/production/TicTacToe - MinMax/Executor.class
new file mode 100644
index 0000000..02da93f
Binary files /dev/null and b/out/production/TicTacToe - MinMax/Executor.class differ
diff --git a/out/production/TicTacToe - MinMax/Game.class b/out/production/TicTacToe - MinMax/Game.class
new file mode 100644
index 0000000..2ffd5c6
Binary files /dev/null and b/out/production/TicTacToe - MinMax/Game.class differ
diff --git a/out/production/TicTacToe - MinMax/META-INF/MANIFEST.MF b/out/production/TicTacToe - MinMax/META-INF/MANIFEST.MF
new file mode 100644
index 0000000..357fd3e
--- /dev/null
+++ b/out/production/TicTacToe - MinMax/META-INF/MANIFEST.MF
@@ -0,0 +1,3 @@
+Manifest-Version: 1.0
+Main-Class: Executor
+
diff --git a/out/production/CodingChallanges/META-INF/CodingChallanges.kotlin_module b/out/production/TicTacToe - MinMax/META-INF/TicTacToe - MinMax.kotlin_module
similarity index 100%
rename from out/production/CodingChallanges/META-INF/CodingChallanges.kotlin_module
rename to out/production/TicTacToe - MinMax/META-INF/TicTacToe - MinMax.kotlin_module
diff --git a/out/production/TicTacToe - MinMax/Minmax.class b/out/production/TicTacToe - MinMax/Minmax.class
new file mode 100644
index 0000000..d6d4981
Binary files /dev/null and b/out/production/TicTacToe - MinMax/Minmax.class differ
diff --git a/out/production/TicTacToe - MinMax/Painter.class b/out/production/TicTacToe - MinMax/Painter.class
new file mode 100644
index 0000000..48e5270
Binary files /dev/null and b/out/production/TicTacToe - MinMax/Painter.class differ
diff --git a/out/production/TicTacToe - MinMax/Test.class b/out/production/TicTacToe - MinMax/Test.class
new file mode 100644
index 0000000..22a1c24
Binary files /dev/null and b/out/production/TicTacToe - MinMax/Test.class differ
diff --git a/out/production/TicTacToe - MinMax/minmax_pseudo.txt b/out/production/TicTacToe - MinMax/minmax_pseudo.txt
new file mode 100644
index 0000000..f2ec103
--- /dev/null
+++ b/out/production/TicTacToe - MinMax/minmax_pseudo.txt
@@ -0,0 +1,9 @@
+Variables:
+player, board, search_depth
+
+Data_structure:
+BinaryTree
+
+Loops:
+recursion
+ for-loop
diff --git a/out/production/TicTacToe_MinMax/Game$1.class b/out/production/TicTacToe_MinMax/Game$1.class
deleted file mode 100644
index 2e92e5c..0000000
Binary files a/out/production/TicTacToe_MinMax/Game$1.class and /dev/null differ
diff --git a/out/production/TicTacToe_MinMax/Game.class b/out/production/TicTacToe_MinMax/Game.class
deleted file mode 100644
index 9e3c030..0000000
Binary files a/out/production/TicTacToe_MinMax/Game.class and /dev/null differ
diff --git a/out/production/TicTacToe_MinMax/GameCharacters$CharacterO.class b/out/production/TicTacToe_MinMax/GameCharacters$CharacterO.class
deleted file mode 100644
index 4f2cf16..0000000
Binary files a/out/production/TicTacToe_MinMax/GameCharacters$CharacterO.class and /dev/null differ
diff --git a/out/production/TicTacToe_MinMax/GameCharacters$CharacterX.class b/out/production/TicTacToe_MinMax/GameCharacters$CharacterX.class
deleted file mode 100644
index d2b7eef..0000000
Binary files a/out/production/TicTacToe_MinMax/GameCharacters$CharacterX.class and /dev/null differ
diff --git a/out/production/TicTacToe_MinMax/GameCharacters.class b/out/production/TicTacToe_MinMax/GameCharacters.class
deleted file mode 100644
index 7213a8b..0000000
Binary files a/out/production/TicTacToe_MinMax/GameCharacters.class and /dev/null differ
diff --git a/out/production/TicTacToe_MinMax/Grid.class b/out/production/TicTacToe_MinMax/Grid.class
deleted file mode 100644
index 979d343..0000000
Binary files a/out/production/TicTacToe_MinMax/Grid.class and /dev/null differ
diff --git a/out/production/TicTacToe_MinMax/MyPanel.class b/out/production/TicTacToe_MinMax/MyPanel.class
deleted file mode 100644
index ee9ece0..0000000
Binary files a/out/production/TicTacToe_MinMax/MyPanel.class and /dev/null differ
diff --git a/out/production/TicTacToe_MinMax/Render.class b/out/production/TicTacToe_MinMax/Render.class
deleted file mode 100644
index 7f718dc..0000000
Binary files a/out/production/TicTacToe_MinMax/Render.class and /dev/null differ