Compare commits
3 Commits
lab2-dev
...
23d8a1b1ce
| Author | SHA1 | Date | |
|---|---|---|---|
| 23d8a1b1ce | |||
| 5f109a0072 | |||
| a9e3c765c6 |
@@ -26,7 +26,7 @@ public class Main {
|
||||
}
|
||||
else if (Objects.equals(args[p], "--offline")) {
|
||||
allow_networking = false;
|
||||
p += 2;
|
||||
p += 1;
|
||||
}
|
||||
else {
|
||||
matrix_file_name = args[p++];
|
||||
@@ -67,6 +67,7 @@ public class Main {
|
||||
System.out.println("Original matrix:");
|
||||
Matrix m = new Matrix();
|
||||
m.init(raw_m);
|
||||
m.print();
|
||||
|
||||
// transposing
|
||||
m.transpose();
|
||||
@@ -89,6 +90,7 @@ public class Main {
|
||||
}
|
||||
} catch (Exception e) {
|
||||
System.out.println("[ERROR] Failed to fetch resource " + output_filename + "from " + remote_url + " due to the following exception: " + e);
|
||||
System.exit(1);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -99,8 +101,8 @@ public class Main {
|
||||
if (!help_file.exists()) {
|
||||
System.err.println("[WARN] Help file is missing.");
|
||||
if (allow_net) {
|
||||
System.err.println("[INFO] Trying to recover it from the git server");
|
||||
fetchResource("http://lab2.kpi.dev:3000/dymik739/oop-labs-collection/raw/branch/lab2-dev/labs/2/src/help.txt", "src/help.txt");
|
||||
System.err.println("[INFO] Trying to recover it from the CDN server");
|
||||
fetchResource("http://lab2.kpi.dev:16554/help.txt", "src/help.txt");
|
||||
} else {
|
||||
System.err.println("[INFO] Networking is disabled, not recovering");
|
||||
System.exit(1);
|
||||
|
||||
@@ -19,7 +19,6 @@ public class Matrix {
|
||||
}
|
||||
|
||||
public void transpose() {
|
||||
print();
|
||||
if (this.m[0].length != this.m.length) {
|
||||
int new_h = this.m[0].length;
|
||||
int new_w = this.m.length;
|
||||
|
||||
Reference in New Issue
Block a user