exo4: fix the class annotation to be included inside the bytecode.
[Project_POO.git] / exo5 / IStrComparator.java
diff --git a/exo5/IStrComparator.java b/exo5/IStrComparator.java
new file mode 100644 (file)
index 0000000..080ba22
--- /dev/null
@@ -0,0 +1,14 @@
+import java.util.Comparator;
+
+class IStrComparator implements Comparator<String> {
+    private String wordToCompare;
+
+    IStrComparator(String w) {
+        wordToCompare = w;
+    }
+
+    public int compare(String str1, String str2) {
+        return str1.compareTo(str2);
+    }
+
+}