-
-
Notifications
You must be signed in to change notification settings - Fork 5
Ch. 14 and 15 Problems #16
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remaining comments which cannot be posted as a review comment to avoid GitHub Rate Limit
reviewdog
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|33 col 3| 'method def modifier' has incorrect indentation level 2, expected level should be 4.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|35 col 1| 'CLASS_DEF' should be separated from previous statement.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|35 col 1| Top-level class Student has to reside in its own source file.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|35 col 36| WhitespaceAround: '{' is not preceded with whitespace.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|36 col 3| 'member def modifier' has incorrect indentation level 2, expected level should be 4.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|36 col 18| Abbreviation in name 'GPA' must contain no more than '1' consecutive capital letters.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|36 col 18| Member name 'GPA' must match pattern '^[a-z][a-z0-9][a-zA-Z0-9]$'.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|37 col 3| 'member def modifier' has incorrect indentation level 2, expected level should be 4.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|38 col 3| 'CTOR_DEF' should be separated from previous statement.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|38 col 3| 'ctor def modifier' has incorrect indentation level 2, expected level should be 4.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|38 col 38| Abbreviation in name 'GPA' must contain no more than '1' consecutive capital letters.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|38 col 38| Parameter name 'GPA' must match pattern '^a-z?$'.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|38 col 42| WhitespaceAround: '{' is not preceded with whitespace.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|39 col 5| 'ctor def' child has incorrect indentation level 4, expected level should be 8.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|40 col 5| 'ctor def' child has incorrect indentation level 4, expected level should be 8.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|41 col 3| 'ctor def rcurly' has incorrect indentation level 2, expected level should be 4.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|42 col 3| 'CTOR_DEF' should be separated from previous statement.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|42 col 3| 'ctor def modifier' has incorrect indentation level 2, expected level should be 4.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|42 col 19| WhitespaceAround: '{' is not preceded with whitespace.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|43 col 5| 'ctor def' child has incorrect indentation level 4, expected level should be 8.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|44 col 5| 'ctor def' child has incorrect indentation level 4, expected level should be 8.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|45 col 3| 'ctor def rcurly' has incorrect indentation level 2, expected level should be 4.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|46 col 3| 'METHOD_DEF' should be separated from previous statement.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|46 col 3| 'method def modifier' has incorrect indentation level 2, expected level should be 4.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|46 col 39| WhitespaceAround: '{' is not preceded with whitespace.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|47 col 5| 'method def' child has incorrect indentation level 4, expected level should be 8.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|48 col 5| 'method def' child has incorrect indentation level 4, expected level should be 8.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|49 col 5| 'for' construct must use '{}'s.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|49 col 5| 'for' has incorrect indentation level 4, expected level should be 8.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|49 col 5| 'for' is not followed by whitespace.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|49 col 5| WhitespaceAround: 'for' is not followed by whitespace. Empty blocks may only be represented as {} when not part of a multi-block statement (4.1.3)
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|50 col 7| 'for' child has incorrect indentation level 6, expected level should be 12.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|51 col 5| 'method def' child has incorrect indentation level 4, expected level should be 8.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|52 col 3| 'method def rcurly' has incorrect indentation level 2, expected level should be 4.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|53 col 3| 'METHOD_DEF' should be separated from previous statement.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|53 col 3| 'method def modifier' has incorrect indentation level 2, expected level should be 4.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|53 col 39| WhitespaceAround: '{' is not preceded with whitespace.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|54 col 5| 'method def' child has incorrect indentation level 4, expected level should be 8.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|55 col 5| 'method def' child has incorrect indentation level 4, expected level should be 8.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|56 col 5| 'for' has incorrect indentation level 4, expected level should be 8.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|56 col 5| 'for' is not followed by whitespace.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|56 col 5| WhitespaceAround: 'for' is not followed by whitespace. Empty blocks may only be represented as {} when not part of a multi-block statement (4.1.3)
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|56 col 29| WhitespaceAround: '{' is not preceded with whitespace.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|57 col 7| 'if' construct must use '{}'s.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|57 col 7| 'if' has incorrect indentation level 6, expected level should be 12.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|57 col 7| 'if' is not followed by whitespace.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|57 col 7| WhitespaceAround: 'if' is not followed by whitespace. Empty blocks may only be represented as {} when not part of a multi-block statement (4.1.3)
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|58 col 9| 'if' child has incorrect indentation level 8, expected level should be 16.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|59 col 5| 'for rcurly' has incorrect indentation level 4, expected level should be 8.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|60 col 5| 'method def' child has incorrect indentation level 4, expected level should be 8.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|61 col 3| 'method def rcurly' has incorrect indentation level 2, expected level should be 4.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|62 col 3| 'METHOD_DEF' should be separated from previous statement.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|62 col 3| 'method def modifier' has incorrect indentation level 2, expected level should be 4.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|62 col 40| WhitespaceAround: '{' is not preceded with whitespace.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|63 col 5| 'method def' child has incorrect indentation level 4, expected level should be 8.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|64 col 5| 'method def' child has incorrect indentation level 4, expected level should be 8.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|65 col 5| 'for' has incorrect indentation level 4, expected level should be 8.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|65 col 5| 'for' is not followed by whitespace.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|65 col 5| WhitespaceAround: 'for' is not followed by whitespace. Empty blocks may only be represented as {} when not part of a multi-block statement (4.1.3)
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|65 col 29| WhitespaceAround: '{' is not preceded with whitespace.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|66 col 7| 'if' construct must use '{}'s.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|66 col 7| 'if' has incorrect indentation level 6, expected level should be 12.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|66 col 7| 'if' is not followed by whitespace.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|66 col 7| WhitespaceAround: 'if' is not followed by whitespace. Empty blocks may only be represented as {} when not part of a multi-block statement (4.1.3)
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|67 col 9| 'if' child has incorrect indentation level 8, expected level should be 16.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|68 col 5| 'for rcurly' has incorrect indentation level 4, expected level should be 8.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|69 col 5| 'method def' child has incorrect indentation level 4, expected level should be 8.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|70 col 3| 'method def rcurly' has incorrect indentation level 2, expected level should be 4.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|71 col 3| 'METHOD_DEF' should be separated from previous statement.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|71 col 3| 'method def modifier' has incorrect indentation level 2, expected level should be 4.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|71 col 17| Abbreviation in name 'getGPA' must contain no more than '1' consecutive capital letters.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|71 col 25| WhitespaceAround: '{' is not preceded with whitespace.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|72 col 5| 'method def' child has incorrect indentation level 4, expected level should be 8.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|73 col 3| 'method def rcurly' has incorrect indentation level 2, expected level should be 4.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|74 col 3| 'METHOD_DEF' should be separated from previous statement.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|74 col 3| 'method def modifier' has incorrect indentation level 2, expected level should be 4.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|74 col 26| WhitespaceAround: '{' is not preceded with whitespace.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|75 col 5| 'method def' child has incorrect indentation level 4, expected level should be 8.
src/com/codefortomorrow/advanced/chapter15/solutions/MeasurableProblem.java|76 col 3| 'method def rcurly' has incorrect indentation level 2, expected level should be 4.
src/com/codefortomorrow/advanced/chapter14/practice/Lexico.java|3 col 15| Using the '.' form of import should be avoided - java.io..
src/com/codefortomorrow/advanced/chapter14/practice/Lexico.java|16 col 20| WhitespaceAround: '{' is not preceded with whitespace.
src/com/codefortomorrow/advanced/chapter14/solutions/Lexico.java|3 col 15| Using the '.' form of import should be avoided - java.io.*.
src/com/codefortomorrow/advanced/chapter14/solutions/Lexico.java|16 col 20| WhitespaceAround: '{' is not preceded with whitespace.
src/com/codefortomorrow/advanced/chapter14/solutions/Lexico.java|18 col 3| 'method def modifier' has incorrect indentation level 2, expected level should be 4.
src/com/codefortomorrow/advanced/chapter14/solutions/Lexico.java|18 col 41| WhitespaceAround: '{' is not preceded with whitespace.
src/com/codefortomorrow/advanced/chapter14/solutions/Lexico.java|19 col 5| 'method def' child has incorrect indentation level 4, expected level should be 8.
src/com/codefortomorrow/advanced/chapter14/solutions/Lexico.java|20 col 5| 'method def' child has incorrect indentation level 4, expected level should be 8.
src/com/codefortomorrow/advanced/chapter14/solutions/Lexico.java|21 col 5| 'try' has incorrect indentation level 4, expected level should be 8.
src/com/codefortomorrow/advanced/chapter14/solutions/Lexico.java|21 col 5| WhitespaceAround: 'try' is not followed by whitespace. Empty blocks may only be represented as {} when not part of a multi-block statement (4.1.3)
src/com/codefortomorrow/advanced/chapter14/solutions/Lexico.java|21 col 8| WhitespaceAround: '{' is not preceded with whitespace.
src/com/codefortomorrow/advanced/chapter14/solutions/Lexico.java|22 col 7| 'try' child has incorrect indentation level 6, expected level should be 12.
src/com/codefortomorrow/advanced/chapter14/solutions/Lexico.java|23 col 7| 'try' child has incorrect indentation level 6, expected level should be 12.
src/com/codefortomorrow/advanced/chapter14/solutions/Lexico.java|25 col 7| 'try' child has incorrect indentation level 6, expected level should be 12.
src/com/codefortomorrow/advanced/chapter14/solutions/Lexico.java|26 col 7| 'try' child has incorrect indentation level 6, expected level should be 12.
src/com/codefortomorrow/advanced/chapter14/solutions/Lexico.java|27 col 7| 'try' child has incorrect indentation level 6, expected level should be 12.
src/com/codefortomorrow/advanced/chapter14/solutions/Lexico.java|28 col 7| 'while' has incorrect indentation level 6, expected level should be 12.
src/com/codefortomorrow/advanced/chapter14/solutions/Lexico.java|28 col 21| WhitespaceAround: '{' is not preceded with whitespace.
src/com/codefortomorrow/advanced/chapter14/solutions/Lexico.java|29 col 9| 'while' child has incorrect indentation level 8, expected level should be 16.
src/com/codefortomorrow/advanced/chapter14/solutions/Lexico.java|30 col 9| 'while' child has incorrect indentation level 8, expected level should be 16.
src/com/codefortomorrow/advanced/chapter14/solutions/Lexico.java|31 col 9| 'while' child has incorrect indentation level 8, expected level should be 16.
src/com/codefortomorrow/advanced/chapter14/solutions/Lexico.java|32 col 7| 'while rcurly' has incorrect indentation level 6, expected level should be 12.
src/com/codefortomorrow/advanced/chapter14/solutions/Lexico.java|33 col 7| 'if' construct must use '{}'s.
src/com/codefortomorrow/advanced/chapter14/solutions/Lexico.java|33 col 7| 'if' has incorrect indentation level 6, expected level should be 12.
src/com/codefortomorrow/advanced/chapter14/solutions/Lexico.java|33 col 7| 'if' is not followed by whitespace.
src/com/codefortomorrow/advanced/chapter14/solutions/Lexico.java|33 col 7| WhitespaceAround: 'if' is not followed by whitespace. Empty blocks may only be represented as {} when not part of a multi-block statement (4.1.3)
src/com/codefortomorrow/advanced/chapter14/solutions/Lexico.java|35 col 7| 'else' construct must use '{}'s.
src/com/codefortomorrow/advanced/chapter14/solutions/Lexico.java|35 col 7| 'else' has incorrect indentation level 6, expected level should be 12.
src/com/codefortomorrow/advanced/chapter14/solutions/Lexico.java|37 col 3| 'try rcurly' has incorrect indentation level 2, expected level should be 8.
src/com/codefortomorrow/advanced/chapter14/solutions/Lexico.java|37 col 5| WhitespaceAround: 'catch' is not followed by whitespace. Empty blocks may only be represented as {} when not part of a multi-block statement (4.1.3)
src/com/codefortomorrow/advanced/chapter14/solutions/Lexico.java|37 col 25| WhitespaceAround: '{' is not preceded with whitespace.
src/com/codefortomorrow/advanced/chapter14/solutions/Lexico.java|38 col 5| 'catch' child has incorrect indentation level 4, expected level should be 12.
src/com/codefortomorrow/advanced/chapter14/solutions/Lexico.java|39 col 3| 'catch rcurly' has incorrect indentation level 2, expected level should be 8.
src/com/codefortomorrow/advanced/chapter14/solutions/Lexico.java|40 col 3| 'method def rcurly' has incorrect indentation level 2, expected level should be 4.
| @@ -0,0 +1,24 @@ | |||
| package com.codefortomorrow.advanced.chapter15.practice; | |||
| /* | |||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[reviewdog] reported by reviewdog 🐶
'/*' should be separated from previous statement.
|
|
||
| Problem adapted from Java SE 9 Textbook | ||
| */ | ||
| public class MeasurableProblem{ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[reviewdog] reported by reviewdog 🐶
WhitespaceAround: '{' is not preceded with whitespace.
| Problem adapted from Java SE 9 Textbook | ||
| */ | ||
| public class MeasurableProblem{ | ||
| public static void main(String[] args){ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[reviewdog] reported by reviewdog 🐶
'method def modifier' has incorrect indentation level 2, expected level should be 4.
| public class MeasurableProblem{ | ||
| public static void main(String[] args){ | ||
| //Add testing code | ||
| } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[reviewdog] reported by reviewdog 🐶
'method def rcurly' has incorrect indentation level 2, expected level should be 4.
| //Add testing code | ||
| } | ||
| } | ||
| interface Measurable{ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[reviewdog] reported by reviewdog 🐶
'INTERFACE_DEF' should be separated from previous statement.
| System.out.println("Smallest: " + test.smallest(students)); | ||
| } | ||
| } | ||
| interface Measurable{ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[reviewdog] reported by reviewdog 🐶
WhitespaceAround: '{' is not preceded with whitespace.
| } | ||
| } | ||
| interface Measurable{ | ||
| abstract double average(Object[] students); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[reviewdog] reported by reviewdog 🐶
'method def modifier' has incorrect indentation level 2, expected level should be 4.
| } | ||
| interface Measurable{ | ||
| abstract double average(Object[] students); | ||
| abstract String largest(Object[] students); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[reviewdog] reported by reviewdog 🐶
'METHOD_DEF' should be separated from previous statement.
| } | ||
| interface Measurable{ | ||
| abstract double average(Object[] students); | ||
| abstract String largest(Object[] students); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[reviewdog] reported by reviewdog 🐶
'method def modifier' has incorrect indentation level 2, expected level should be 4.
| interface Measurable{ | ||
| abstract double average(Object[] students); | ||
| abstract String largest(Object[] students); | ||
| abstract String smallest(Object[] students); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[reviewdog] reported by reviewdog 🐶
'METHOD_DEF' should be separated from previous statement.
| } | ||
| } | ||
|
|
||
| interface Measurable { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[reviewdog] reported by reviewdog 🐶
Top-level class Measurable has to reside in its own source file.
| //add interface code here | ||
| } | ||
|
|
||
| class Student implements Measurable { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[reviewdog] reported by reviewdog 🐶
Top-level class Student has to reside in its own source file.
| } | ||
| } | ||
|
|
||
| interface Measurable { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[reviewdog] reported by reviewdog 🐶
Top-level class Measurable has to reside in its own source file.
| abstract String smallest(Object[] students); | ||
| } | ||
|
|
||
| class Student implements Measurable { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[reviewdog] reported by reviewdog 🐶
Top-level class Student has to reside in its own source file.
| } | ||
|
|
||
| class Student implements Measurable { | ||
| private double GPA; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[reviewdog] reported by reviewdog 🐶
Abbreviation in name 'GPA' must contain no more than '1' consecutive capital letters.
| line2 = br2.readLine(); | ||
| c = line1.compareTo(line2); | ||
| } | ||
| if(c > 0) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[reviewdog] reported by reviewdog 🐶
WhitespaceAround: 'if' is not followed by whitespace. Empty blocks may only be represented as {} when not part of a multi-block statement (4.1.3)
| } | ||
| if(c > 0) | ||
| System.out.println("File 2"); | ||
| else |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[reviewdog] reported by reviewdog 🐶
'else' construct must use '{}'s.
| System.out.println("File 2"); | ||
| else | ||
| System.out.println("File 1"); | ||
| } catch(IOException e){ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[reviewdog] reported by reviewdog 🐶
WhitespaceAround: 'catch' is not followed by whitespace. Empty blocks may only be represented as {} when not part of a multi-block statement (4.1.3)
| System.out.println("File 2"); | ||
| else | ||
| System.out.println("File 1"); | ||
| } catch(IOException e){ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[reviewdog] reported by reviewdog 🐶
WhitespaceAround: '{' is not preceded with whitespace.
| else | ||
| System.out.println("File 1"); | ||
| } catch(IOException e){ | ||
| e.printStackTrace(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[reviewdog] reported by reviewdog 🐶
'catch' child has incorrect indentation level 10, expected level should be 12.
ARajan1084
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nice work. looks great.
AlveeraMunshi
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good!
| line2 = br2.readLine(); | ||
| c = line1.compareTo(line2); | ||
| } | ||
| if (c > 0) System.out.println("File 2"); else System.out.println( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[reviewdog] reported by reviewdog 🐶
'if' construct must use '{}'s.
| line2 = br2.readLine(); | ||
| c = line1.compareTo(line2); | ||
| } | ||
| if (c > 0) System.out.println("File 2"); else System.out.println( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[reviewdog] reported by reviewdog 🐶
'else' construct must use '{}'s.
| } | ||
| if (c > 0) System.out.println("File 2"); else System.out.println( | ||
| "File 1" | ||
| ); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[reviewdog] reported by reviewdog 🐶
Only one statement per line allowed.
Ch. 14 - File I/O Medium Difficulty Lexicographical Problem
Ch. 15 - Interfaces High Difficulty Problem
Josh Joseph