We have vectors as follows:
c1<-c(10,40,28)
c2<-c(50,55,44)
this code:
c1>25&&c2>25
returns FALSE which I understand (&& return always one, scalar value, if it encounters FALSE values it doesn't make any sesne to check the rest values in vectors)
However in this example:
c3<-c(40,10,28)
c4<-c(50,15,44)
for this code:
c3>25&&c4>25
it returns TRUE. I don't understand why. I read that for && and || only first elements are being checked but for me it doesn't make sense. values 40 and 50 (those first elements) return TRUE but pair: 10 and 15 returns FALSE and for me teh output should be FALSE beacuse rest ofe the vector values (besides first elenents) are not TRUE and the whole output should be FALSE. That's misleading.
When I compare 2 vectors such as above - I would like to return FALSE not TRUE because they don't meet the condition (>25). How can I compare them to return FALSE instead of TRUE )(for me && is useless in this case)