Which lambda expression can replace the instance of new BiologyMaterial() in the Scientist class and produce the

Question:

Which lambda expression can replace the instance of new BiologyMaterial() in the Scientist class and produce the same results under various inputted values? 

image text in transcribed

A. (p,q) -> q==null ? p : p+1

B. (c,d) -> {int d=1; return c!=null ? d+1 : d;}

C. (x,y) -> {return x==null ? y : y+1;}

D. (a,b) -> 1

E. None of the above.

Fantastic news! We've Found the answer you've been seeking!

Step by Step Answer:

Question Posted: