diff --git a/Semester 2/Assignments/lab3_CalebFontenot/Printed HTMLs/FanList.html b/Semester 2/Assignments/lab3_CalebFontenot/Printed HTMLs/FanList.html
new file mode 100644
index 0000000..d8a5a05
--- /dev/null
+++ b/Semester 2/Assignments/lab3_CalebFontenot/Printed HTMLs/FanList.html
@@ -0,0 +1,104 @@
+
+
+
+FanList.java
+
+
+
+
+/home/caleb/ASDV-Java/Semester 2/Assignments/lab3_CalebFontenot/src/main/java/com/calebfontenot/lab3_calebfontenot/FanList.java |
+
+
+
+
+
+package com.calebfontenot.lab3_calebfontenot;
+
+import java.util.Scanner;
+
+
+
+@author
+
+public class FanList {
+
+ private Fan[] list;
+
+
+ public FanList(int listSize)
+ {
+ list = new Fan[listSize];
+ createListObjects();
+ }
+
+
+ private void createListObjects()
+ {
+ Scanner scan = new Scanner(System.in);
+ for (int i = 0; i < list.length; ++i) {
+ Fan fan = new Fan();
+ System.out.println("Enter FAN data for fan " + (i + 1)
+ + ": color, radius, speed(1, 2 or 3) and if on (t, f)");
+ String color = scan.next();
+ int radius = scan.nextInt();
+ int speed = scan.nextInt();
+ String on = scan.next();
+ fan.setSpeed(speed);
+ fan.setRadius(radius);
+ fan.setColor(color);
+ if ("t".compareToIgnoreCase(on) == 0) {
+ fan.setOn(true);
+ } else {
+ fan.setOn(false);
+ }
+ list[i] = fan;
+ System.out.println("----------------------------------------");
+ }
+ }
+
+ @Override
+ public String toString()
+ {
+ String s = "FanList{" + "list=\n";
+ for (int i = 0; i < list.length; ++i) {
+ s += list[i].toString() + "\n-----------------------\n";
+ }
+ s += '}';
+ return s;
+ }
+
+ public void sortListByRadius()
+ {
+ for (int i = 0; i < list.length - 1; ++i) {
+ for (int j = i + 1; j < list.length; ++j) {
+ if (list[i].getRadius() > list[j].getRadius()) {
+ Fan temp = list[i];
+ list[i] = list[j];
+ list[j] = temp;
+ }
+ }
+ }
+ }
+ public static void main(String[] args)
+ {
+ FanList fanList = new FanList(3);
+ System.out.println(fanList);
+ fanList.sortListByRadius();
+ System.out.println(fanList.toString());
+ }
+}
+
+
+
diff --git a/Semester 2/Assignments/lab3_CalebFontenot/Printed HTMLs/Stock.html b/Semester 2/Assignments/lab3_CalebFontenot/Printed HTMLs/Stock.html
new file mode 100644
index 0000000..f8c02f2
--- /dev/null
+++ b/Semester 2/Assignments/lab3_CalebFontenot/Printed HTMLs/Stock.html
@@ -0,0 +1,144 @@
+
+
+
+Stock.java
+
+
+
+
+/home/caleb/ASDV-Java/Semester 2/Assignments/lab3_CalebFontenot/src/main/java/com/calebfontenot/lab3_calebfontenot/Stock.java |
+
+
+
+
+
+package com.calebfontenot.lab3_calebfontenot;
+
+
+
+@author
+
+public class Stock {
+
+ private String symbol;
+ private String name;
+ private double previousClosingPrice;
+ private double currentPrice;
+
+
+
+
+@return
+
+ public double getCurrentPrice()
+ {
+ return currentPrice;
+ }
+
+
+
+
+@param
+
+ public void setCurrentPrice(double currentPrice)
+ {
+ this.currentPrice = currentPrice;
+ }
+
+
+
+
+
+@return
+
+ public double getPreviousClosingPrice()
+ {
+ return previousClosingPrice;
+ }
+
+
+
+
+@param
+
+ public void setPreviousClosingPrice(double previousClosingPrice)
+ {
+ this.previousClosingPrice = previousClosingPrice;
+ }
+
+
+
+
+
+@return
+
+ public String getName()
+ {
+ return name;
+ }
+
+
+
+
+@param
+
+ public void setName(String name)
+ {
+ this.name = name;
+ }
+
+
+
+
+@return
+
+ public String getSymbol()
+ {
+ return symbol;
+ }
+
+
+
+
+@param
+
+ public void setSymbol(String symbol)
+ {
+ this.symbol = symbol;
+ }
+
+ public double getChangePercent() {
+ return this.currentPrice - this.previousClosingPrice;
+
+ }
+
+ @Override
+ public String toString()
+ {
+ return "Stock{" + "symbol=" + symbol + ", name=" + name + ", previousClosingPrice=" + previousClosingPrice + ", currentPrice=" + currentPrice + "}"+ "\n" + "Change in Percent: " + this.getChangePercent();
+ }
+ public static void main(String[] args)
+ {
+ Stock stock1 = new Stock();
+ stock1.setSymbol("ORCL");
+ stock1.setName("Oracle Corporation");
+ stock1.setPreviousClosingPrice(34.5);
+ stock1.setCurrentPrice(34.35);
+ System.out.println(stock1);
+ }
+}
+
+
+
diff --git a/Semester 2/Assignments/lab3_CalebFontenot/Printed HTMLs/StockList.html b/Semester 2/Assignments/lab3_CalebFontenot/Printed HTMLs/StockList.html
new file mode 100644
index 0000000..303f9dd
--- /dev/null
+++ b/Semester 2/Assignments/lab3_CalebFontenot/Printed HTMLs/StockList.html
@@ -0,0 +1,100 @@
+
+
+
+StockList.java
+
+
+
+
+/home/caleb/ASDV-Java/Semester 2/Assignments/lab3_CalebFontenot/src/main/java/com/calebfontenot/lab3_calebfontenot/StockList.java |
+
+
+
+
+
+package com.calebfontenot.lab3_calebfontenot;
+
+import java.util.Scanner;
+
+
+
+@author
+
+public class StockList {
+
+ private Stock[] list;
+
+
+ public StockList(int listSize)
+ {
+ list = new Stock[listSize];
+ createListObjects();
+ }
+
+
+ private void createListObjects()
+ {
+ Scanner scan = new Scanner(System.in);
+ for (int i = 0; i < list.length; ++i) {
+ Stock stock = new Stock();
+ System.out.println("Enter Stock data for stock " + (i + 1)
+ + ": symbol, name, previous closing price, and current price");
+ String symbol = scan.next();
+ String name = scan.next();
+ double previousClosingPrice = scan.nextDouble();
+ double currentPrice = scan.nextDouble();
+ stock.setSymbol(symbol);
+ stock.setName(name);
+ stock.setPreviousClosingPrice(previousClosingPrice);
+ stock.setCurrentPrice(currentPrice);
+ list[i] = stock;
+ System.out.println("----------------------------------------");
+ }
+ }
+
+ @Override
+ public String toString()
+ {
+ String s = "StockList{" + "list=\n";
+ for (int i = 0; i < list.length; ++i) {
+ s += list[i].toString() + "\n-----------------------\n";
+ }
+ s += '}';
+ return s;
+ }
+
+ public void sortByChangeInPercentage()
+ {
+ for (int i = 0; i < list.length - 1; ++i) {
+ for (int j = i + 1; j < list.length; ++j) {
+ if (list[i].getChangePercent() > list[j].getChangePercent()) {
+ Stock temp = list[i];
+ list[i] = list[j];
+ list[j] = temp;
+ }
+ }
+ }
+ }
+ public static void main(String[] args)
+ {
+ StockList stockList = new StockList(3);
+ System.out.println(stockList);
+ stockList.sortByChangeInPercentage();
+ System.out.println(stockList);
+ }
+}
+
+
+
diff --git a/Semester 2/Assignments/lab3_CalebFontenot/Printed HTMLs/fan.html b/Semester 2/Assignments/lab3_CalebFontenot/Printed HTMLs/fan.html
new file mode 100644
index 0000000..e771112
--- /dev/null
+++ b/Semester 2/Assignments/lab3_CalebFontenot/Printed HTMLs/fan.html
@@ -0,0 +1,160 @@
+
+
+
+Fan.java
+
+
+
+
+/home/caleb/ASDV-Java/Semester 2/Assignments/lab3_CalebFontenot/src/main/java/com/calebfontenot/lab3_calebfontenot/Fan.java |
+
+
+
+
+package com.calebfontenot.lab3_calebfontenot;
+
+
+ *
+ * @author caleb
+ */
+public class Fan {
+ // Constants
+ public static final int SLOW = 1;
+ public static final int MEDIUM = 2;
+ public static final int FAST = 3;
+
+ private int speed;
+ private boolean isOn;
+ private int radius;
+ private String color;
+
+ public Fan() {
+ this.speed = 1;
+ this.isOn = false;
+ this.radius = 5;
+ this.color = "blue";
+ }
+
+ /**
+ * Get the value of color
+ *
+ * @return the value of color
+ */
+ public String getColor()
+ {
+ return color;
+ }
+
+ /**
+ * Set the value of color
+ *
+ * @param color new value of color
+ */
+ public void setColor(String color)
+ {
+ this.color = color;
+ }
+
+ /**
+ * Get the value of radius
+ *
+ * @return the value of radius
+ */
+ public int getRadius()
+ {
+ return radius;
+ }
+
+ /**
+ * Set the value of radius
+ *
+ * @param radius new value of radius
+ */
+ public void setRadius(int radius)
+ {
+ this.radius = radius;
+ }
+
+ /**
+ * Get the value of isOn
+ *
+ * @return the value of isOn
+ */
+ public boolean isOn()
+ {
+ return isOn;
+ }
+
+ /**
+ * Set the value of isOn
+ *
+ * @param isOn new value of isOn
+ */
+ public void setOn(boolean isOn)
+ {
+ this.isOn = isOn;
+ }
+
+ /**
+ * Get the value of speed
+ *
+ * @return the value of speed
+ */
+ public int getSpeed()
+ {
+ return speed;
+ }
+
+ /**
+ * Set the value of speed
+ *
+ * @param speed new value of speed
+ */
+ public void setSpeed(int speed)
+ {
+ this.speed = speed;
+ }
+
+ @Override
+ public String toString()
+ {
+ String returnString;
+ if (this.isOn) {
+ returnString = "fan is on. ";
+ }
+ else {
+ returnString = "fan is off. ";
+ }
+ returnString += "{" + "speed=" + speed + ", radius=" + radius + ", color=" + color + '}';
+ return returnString;
+ }
+
+ public static void main(String[] args)
+ {
+ Fan fan1 = new Fan();
+ fan1.setSpeed(Fan.FAST);
+ fan1.setRadius(10);
+ fan1.setColor("yellow");
+ fan1.setOn(true);
+ System.out.println(fan1);
+
+ Fan fan2 = new Fan();
+ fan2.setSpeed(Fan.MEDIUM);
+ fan2.setRadius(5);
+ fan2.setColor("blue");
+ fan2.setOn(false);
+ System.out.println(fan2.toString());
+ }
+}
+
+
+