writing code for 3 files

This commit is contained in:
2026-05-13 13:37:57 +03:30
parent 7e0386ce16
commit e11db0275d
4 changed files with 49 additions and 18 deletions
+14
View File
@@ -12,6 +12,20 @@ public class Main {
// TODO: You can test your code here before you run the unit tests.
// Example: Call your sorting methods, iterate through the returned list,
// and print out the movies to see if they match the expected results in the Help folder.
System.out.println("=== Sorted By Title ===");
for (Movie movie : parser.sortByTitle()) {
System.out.println(movie);
}
System.out.println("\n=== Sorted By Rating ===");
for (Movie movie : parser.sortByRating()) {
System.out.println(movie);
}
System.out.println("\n=== Sorted By Year ===");
for (Movie movie : parser.sortByYear()) {
System.out.println(movie);
}
System.out.println("Movies parsed successfully! Total movies: " + parser.sortByTitle().size());