Getting Started with Adobe After Effects - Part 6: Motion Blur
A collection of quick technology learning tips from what people around you learn every day

Zip Operater in LINQ

Jun 13 2011 10:57AM by Kirti M.Darji   

Recently I am surfing on net I found useful post for LINQ there is a Zip Operator is introduce in LINQ thread two list together

eg.

string[] codes = { "CAD","HRK","ILS", "JOD", "LTL"};
string[] states =
{
   " Canadian Dollar",
   "Croatian Kuna",
   "Israeli Shekel",
   " Jordanian Dinar",
   "Latvian Lat"
};

A single LINQ statement can stitch the two lists together

var CodesWithcurruncy =
   codes.Zip(
      states,
      (code, Currency) => code + ": " + Currency);

Output will be

CAD:Canadian Dollar
HRK:Croatian Kuna
ILS:Israeli Shekel
JOD:Jordanian Dinar
LTL:Latvian Lat

Thank You,

Read More..   [17 clicks]

Published under: General Technology Tips ·  ·  ·  · 


Kirti M.Darji
10 · 16% · 4983
6
 
0
Knew
 
 
0
Incorrect
 
0
Interesting
 
0
Forgotten



Submit

1  Comments  

  • Good tip....

    commented on Jun 13 2011 11:02AM
    Ramireddy
    2 · 41% · 12972

Your Comment


Sign Up or Login to post a comment.

"Zip Operater in LINQ " rated 5 out of 5 by 6 readers
Zip Operater in LINQ , 5.0 out of 5 based on 6 ratings
    Copyright © Rivera Informatic Private Ltd Contact us      Privacy Policy      Terms of use      Report Abuse      Advertising      [ZULU1097]