style: format code (#4212)

close #4204
This commit is contained in:
acbin
2023-06-09 18:52:05 +08:00
committed by GitHub
parent ad03086f54
commit 00282efd8b
521 changed files with 5233 additions and 7309 deletions

View File

@@ -19,10 +19,7 @@ public class SkylineProblem {
String input = sc.next();
String[] data = input.split(",");
this.add(
Integer.parseInt(data[0]),
Integer.parseInt(data[1]),
Integer.parseInt(data[2])
);
Integer.parseInt(data[0]), Integer.parseInt(data[1]), Integer.parseInt(data[2]));
}
this.print(this.findSkyline(0, num - 1));
@@ -62,10 +59,7 @@ public class SkylineProblem {
return this.mergeSkyline(sky1, sky2);
}
public ArrayList<Skyline> mergeSkyline(
ArrayList<Skyline> sky1,
ArrayList<Skyline> sky2
) {
public ArrayList<Skyline> mergeSkyline(ArrayList<Skyline> sky1, ArrayList<Skyline> sky2) {
int currentH1 = 0, currentH2 = 0;
ArrayList<Skyline> skyline = new ArrayList<>();
int maxH = 0;