Created
December 8, 2016 01:37
-
-
Save nazmul202101/261fa5722d173bebe67795c003e2f766 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//Given two temperatures, return true if one is less than 0 and the other is greater than 100. | |
//icyHot(120, -1) → true | |
//icyHot(-1, 120) → true | |
//icyHot(2, 120) → false | |
public boolean icyHot(int temp1, int temp2) { | |
if(temp1<0 && temp2>100 || temp2<0 && temp1>100 ){ | |
return true; | |
} | |
else{ | |
return false; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment