#Dead Code Error
1 messages · Page 1 of 1 (latest)
While you are waiting for getting help, here are some tips to improve your experience:
If nobody is calling back, that usually means that your question was not well asked and hence nobody feels confident enough answering. Try to use your time to elaborate, provide details, context, more code, examples and maybe some screenshots. With enough info, someone knows the answer for sure.
Don't forget to close your thread using the command </help-thread close:1027500463647621170> when your question has been answered, thanks.
When can the if be true ?
wdym
I'm confused with your question
theres no if true statement for the variables inside
if thats what you mean
are you sure about that
Yes
what does null + null do ?
what does null + null mean
let's say you write null + null in your program
The Operator + is undefined for the argument type(s) Null, null
yes
if(result + result2 != null) {
}
this is your code, and you have a condition where you add two values together
how can result + result2 be null ?
please answer my questions
result + result2 is null if input is incorrect
englishToFrench.put("hello", "salut");
englishToFrench.put("you", "vous");
englishToFrench.put("beer", "bière");
englishToFrench.put("table", "tableau");
englishToFrench.put("chair", "chaise");
englishToFrench.put("i", "je");
englishToFrench.put("the", "la/le");
englishToFrench.put("cannot", "ne peux pas");
englishToFrench.put("monitor", "surveiller");
}
private void fillEnglishToGerman() {
englishToGerman.put("hello", "hallo");
englishToGerman.put("saussage", "wurst");
englishToGerman.put("beer", "bier");
englishToGerman.put("table", "tisch");
englishToGerman.put("chair", "stuhl");
englishToGerman.put("i", "ich");
englishToGerman.put("you", "du/sie");
englishToGerman.put("the", "der/die/das");
englishToGerman.put("work", "arbeit");
Detected code, here are some useful tools:
if it is not one of those
.
wdym
how can result + result2 be null ?
what result and result must be equal to so this condition is true ?
that's not my question
if(result + result2 != null) {
}
what result and result2 must be equal to in order for this to be false ?
null
so in this case
if(null + null != null) {
}
you are doing this
do you see the problem ?
yes
result == null && result2 == null
!solved
@sweet glade read the last message