File tree Expand file tree Collapse file tree 2 files changed +3
-21
lines changed
src/main/java/com/lzw/solutions/uva/p138 Expand file tree Collapse file tree 2 files changed +3
-21
lines changed Original file line number Diff line number Diff line change 119119 <artifactId >exec-maven-plugin</artifactId >
120120 <version >3.5.0</version >
121121 <configuration >
122- <executable >java </executable >
122+ <executable >bash </executable >
123123 <arguments >
124- <argument >-cp</argument >
125- <argument >${project.build.directory} /classes</argument >
126- <argument >com.lzw.solutions.uva.${problem} .Main</argument >
127- <argument >< </argument >
128- <argument >src/main/resources/uva/${problem} /1.in</argument >
124+ <argument >-c</argument >
125+ <argument >java -cp ${project.build.directory} /classes com.lzw.solutions.uva.${problem} .Main < src/main/resources/uva/${problem} /1.in</argument >
129126 </arguments >
130127 </configuration >
131128 </plugin >
Original file line number Diff line number Diff line change @@ -51,23 +51,8 @@ void close() throws IOException {
5151 }
5252
5353 public static void main (String [] args ) throws Exception {
54- FileInputStream inStream = null ;
55- PrintStream outStream = null ;
56- boolean isLocal = System .getProperty ("os.name" ).equals ("Mac OS X" );
57- if (isLocal ) {
58- inStream = new FileInputStream ("1.in" );
59- // outStream = new PrintStream("1.out");
60- System .setIn (inStream );
61- // System.setOut(outStream);
62- }
63-
6454 Main main = new Main ();
6555 main .solve ();
6656 main .close ();
67-
68- if (isLocal ) {
69- inStream .close ();
70- // outStream.close();
71- }
7257 }
7358}
You can’t perform that action at this time.
0 commit comments