Compare commits

...

7 Commits

Author SHA1 Message Date
vala
7d60e8260d now with 10% less typos (probably) 2019-12-02 19:14:29 +01:00
vala
80146fc041 i failed at something 2019-12-02 19:12:34 +01:00
vala
32094afe55 added input number list 2019-12-02 18:59:55 +01:00
vala
5c7d0290f7 because java is needy of its file extensions 2019-12-02 18:51:41 +01:00
vala
d2c27aaa74 some fuarkin folders, eh? 2019-12-02 18:49:59 +01:00
vala
13a675403b fixed some syntax shit 2019-12-02 18:43:29 +01:00
vala
1786441e13 Added more shitty java code for everyone to laugh at 2019-12-02 18:41:15 +01:00
2 changed files with 125 additions and 0 deletions

View File

@ -0,0 +1,25 @@
import java.io.File;
import java.io.FileNotFoundException;
import java.util.Scanner;
public class FuelFinder{
public static void main(String[] vala){
File file = new File("input.txt");
try {
Scanner sc = new Scanner(file);
while (sc.hasNextLine()) {
int i = sc.nextInt();
System.out.println(i);
}
sc.close();
}
catch (FileNotFoundException e) {
e.printStackTrace();
}
}
public static int FuelNeeded(int inp){
return ((inp/3)-2);
}
}

100
advent-of-code/01/input.txt Normal file
View File

@ -0,0 +1,100 @@
70904
66770
118678
58460
128566
60820
107153
113196
52413
118335
96711
88120
129744
64049
90586
54466
55693
102407
148273
110281
111814
60951
102879
135253
130081
86645
72934
147097
74578
124073
100003
103314
86468
84557
94232
120012
64372
143081
96664
148076
147357
139897
113139
143022
144298
81293
53679
139311
107156
121730
132519
132666
80464
111118
76734
139023
111287
126811
130539
129173
67549
102058
72673
91194
64753
59488
126300
94407
126813
60028
95129
79270
123465
60966
111920
76549
110195
119975
112557
129676
104941
89583
121895
108901
135247
75129
148646
131128
78931
111637
72752
140761
57387
85684
77596
134159
63031
148361
133856
82022