Unlike SelectMany a Join clause can't depend on the "current" value of the other range variables - so this will work: from r1 in Enumerable. Range(1, 10) let q = Enumerable. Range(1, 20) from q1 in q where r1 == q1 select r1 but the join won't If you could elaborate on what you're trying to do, we may be able to help more.
Unlike SelectMany, a Join clause can't depend on the "current" value of the other range variables - so this will work: from r1 in Enumerable. Range(1, 10) let q = Enumerable. Range(1, 20) from q1 in q where r1 == q1 select r1; ... but the join won't.
If you could elaborate on what you're trying to do, we may be able to help more.
I've updated the question with the solution that works for me as it is not possible to use let. But can you explain a bit about the restriction on the let clause? – Dmitry Lobanov Sep 12 at 9:49 @Dmitry: It's not so much a restriction on the let clause as a restriction on the join clause - in the join case, Enumerable.
Range is called once for the whole query, whereas using let it would be called *once per element of r1. – Jon Skeet Sep 12 at 10:07.
AFAIK the join is evaluated BEFORE the let... Here is blog entry on MSDN explaining this more elaborate - blogs.msdn.com/b/wesdyer/archive/2007/01....
Join q1 in Enumerable. From r1 in Enumerable. Let q = Enumerable.
IEnumerable q = Enumerable. From r1 in Enumerable.
I cant really gove you an answer,but what I can give you is a way to a solution, that is you have to find the anglde that you relate to or peaks your interest. A good paper is one that people get drawn into because it reaches them ln some way.As for me WW11 to me, I think of the holocaust and the effect it had on the survivors, their families and those who stood by and did nothing until it was too late.