-
Notifications
You must be signed in to change notification settings - Fork 0
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
My hw01 #1
base: master
Are you sure you want to change the base?
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.
resolve comment
Where is the drawDiamond task?
src/hw/one/GameScore.java
Outdated
|
||
public static int GameForecastCalculator(int teamAscore, int teamBscore, int teamAscoreGuess, int teamBscoreGuess) { | ||
|
||
if (teamAscore == teamAscoreGuess && teamBscore == teamBscoreGuess) { |
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.
use ternary operator here
public class GameScore { | ||
|
||
public static int GameForecastCalculator(int teamAscore, int teamBscore, int teamAscoreGuess, int teamBscoreGuess) { | ||
|
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.
remove redundant line
@@ -0,0 +1,11 @@ | |||
package hw.one; | |||
|
|||
public class Main { |
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.
Why do you need this class?
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.
To test other classes.
src/hw/one/PowNumber.java
Outdated
|
||
public class PowNumber { | ||
public static double sqrtNum(int number) { | ||
double result; |
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.
write
return number * number;
and delete
double result;
src/hw/one/PowNumber.java
Outdated
} | ||
|
||
public static double cubeNum(int number) { | ||
double result; |
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.
the same
src/hw/one/PowNumber.java
Outdated
} | ||
return result; | ||
} | ||
|
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.
remove redundant line
Task added Task 01, 03 edited
Task added Task 01, 03 edited
Task added Task 01, 03 edited
Task added Task 01, 03 edited
@@ -0,0 +1,33 @@ | |||
package hw.one; | |||
|
|||
public class DiamondBuilder { |
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.
this method doesn't work with even number
No description provided.