<edited by mod>
Having this expression...
I'm slowly learning this crazy Linq thing... maybe. Actually, this leads me to a question... is there a way to use a lambda here to run it through a TryParse? I might be a little confused on how lamdas work, but I was thinking something like...
... or something to that effect. That code doesn't compile, so am I way out to lunch or is there a way to do it?
*Edit: Haha, curtis read my mind... kinda. How would you use it with TryParse?
Having this expression...
Code:
int[] n = (from ch in "48727" select int.Parse(ch.ToString())).ToArray();
Code:
int [] n = (from ch in "48727" select (ch => int r; if (int.TryParse(ch.ToString(), out i) return i;)).ToArray();
*Edit: Haha, curtis read my mind... kinda. How would you use it with TryParse?
Comment