{"version":"1.0","type":"rich","published":"2009-10-21 00:00:00","url":"https://tnakamura.hatenablog.com/entry/20091021/list_comprehension","height":"190","blog_title":"present","categories":["C#","Python"],"title":"\u30ea\u30b9\u30c8\u5185\u5305\u8868\u73fe","author_name":"griefworker","width":"100%","provider_url":"https://hatena.blog","html":"<iframe src=\"https://hatenablog-parts.com/embed?url=https%3A%2F%2Ftnakamura.hatenablog.com%2Fentry%2F20091021%2Flist_comprehension\" title=\"\u30ea\u30b9\u30c8\u5185\u5305\u8868\u73fe - present\" class=\"embed-card embed-blogcard\" scrolling=\"no\" frameborder=\"0\" style=\"display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;\"></iframe>","author_url":"https://blog.hatena.ne.jp/griefworker/","blog_url":"https://tnakamura.hatenablog.com/","description":"Python \u306e\u30b5\u30f3\u30d7\u30eb\u30b3\u30fc\u30c9\u3067\u3001\u3088\u304f\u6b21\u306e\u3088\u3046\u306a\u66f8\u304d\u65b9\u3092\u898b\u304b\u3051\u307e\u3059\u3002 [f(x) for x in col] \u3053\u306e\u66f8\u304d\u65b9\u3001\u300c\u30ea\u30b9\u30c8\u5185\u5305\u8868\u73fe\u300d\u3068\u547c\u3073\u307e\u3059\u3002\u3053\u308c\u3092\u521d\u3081\u3066\u898b\u305f\u3068\u304d\u3001\u79c1\u306f\u4f55\u3092\u3084\u3063\u3066\u3044\u308b\u306e\u304b\u5168\u304f\u5206\u304b\u308a\u307e\u305b\u3093\u3067\u3057\u305f\u3002\u8abf\u3079\u3066\u307f\u308b\u3068\u3001\u3069\u3046\u3084\u3089\u6b21\u306e\u51e6\u7406\u3092\u884c\u3046\u3088\u3046\u3067\u3059\u3002 col \u306e\u5404\u8981\u7d20\u3092 x \u306b\u4ee3\u5165 f(x) \u3092\u8a55\u4fa1 f(x) \u306e\u7d50\u679c\u3092\u96c6\u3081\u305f\u914d\u5217\u3092\u8fd4\u3059 C# \u3067\u540c\u3058\u51e6\u7406\u3092\u3059\u308b\u306a\u3089\u3001\u6b21\u306e\u3088\u3046\u306b\u66f8\u3051\u307e\u3059\u3002 col.Select(x => f(x)); \u5de6\u304b\u3089\u53f3\u306b\u8aad\u3081\u308b\u3076\u3093\u3001\u3053\u3061\u3089\u304c\u5206\u304b\u308a\u3084\u3059\u3044\u3002\u6163\u308c\u3082\u3042\u308b\u3067\u3057\u3087\u3046\u304c\uff57\u3053\u306e\u30ea\u30b9\u30c8\u5185\u5305\u8868\u73fe\u3001\u6b21\u306e\u3088\u3046\u306b\u66f8\u3051\u3070\u3001\u96c6\u3081\u308b\u8981\u7d20\u3092\u7d5e\u308a\u8fbc\u3081\u307e\u3059\u3002 [f(x) for\u2026","provider_name":"Hatena Blog","image_url":null}