Axel loop update fixes.
parent
4bb978cede
commit
6b0c7d3ad8
|
@ -20,6 +20,7 @@ public class Axel {
|
||||||
while (!stop) {
|
while (!stop) {
|
||||||
|
|
||||||
try {
|
try {
|
||||||
|
spr.updateSpreadsheet();
|
||||||
System.out.println(spr);
|
System.out.println(spr);
|
||||||
System.out.println("\nHILFE (Für eine Anleitung.)\n");
|
System.out.println("\nHILFE (Für eine Anleitung.)\n");
|
||||||
System.out.print("KOMMANDO: ");
|
System.out.print("KOMMANDO: ");
|
||||||
|
|
|
@ -281,7 +281,7 @@ public class Spreadsheet {
|
||||||
for(int r = getRow(startCellName)-1; r<getRow(endCellName); r++)
|
for(int r = getRow(startCellName)-1; r<getRow(endCellName); r++)
|
||||||
for(int c = getCol(startCellName)-1; c<getCol(endCellName); c++)
|
for(int c = getCol(startCellName)-1; c<getCol(endCellName); c++)
|
||||||
if(!cells[r][c].isEmpty()) {
|
if(!cells[r][c].isEmpty()) {
|
||||||
result += Long.parseLong(cells[r][c].getValue());
|
result += Double.parseDouble(cells[r][c].getValue());
|
||||||
counter++;
|
counter++;
|
||||||
}
|
}
|
||||||
result /= counter;
|
result /= counter;
|
||||||
|
@ -472,7 +472,7 @@ public class Spreadsheet {
|
||||||
System.out.println("\nEnter zum fortfahren.");
|
System.out.println("\nEnter zum fortfahren.");
|
||||||
cs.nextLine();
|
cs.nextLine();
|
||||||
}else {
|
}else {
|
||||||
cells[getRow(inputs.get(0)) - 1][getCol(inputs.get(0)) - 1].setFormula(inputs.get(1));
|
cells[getRow(inputs.get(0))-1][getCol(inputs.get(0))-1].setFormula(inputs.get(1));
|
||||||
System.out.println("\nEnter zum fortfahren.");
|
System.out.println("\nEnter zum fortfahren.");
|
||||||
cs.nextLine();
|
cs.nextLine();
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue