Hi I want to have a condition, which when it is nil, it true, or it call check method and return true/false. For example:
(apple.nil? || apple.sweet?) && (pear.nil? || pear.sweet?) It checks if all the fruits are sweet(only apple&pear here). Is there any ruby idiom to simplify this code?
Cheers