{"url":"https://javascripter.hatenablog.com/entry/20080828/1219929188","blog_title":"\u7d20\u4eba\u304c\u30d7\u30ed\u30b0\u30e9\u30df\u30f3\u30b0\u3092\u52c9\u5f37\u3057\u3066\u3044\u305f\u30d6\u30ed\u30b0","title":"static\u5909\u6570","html":"<iframe src=\"https://hatenablog-parts.com/embed?url=https%3A%2F%2Fjavascripter.hatenablog.com%2Fentry%2F20080828%2F1219929188\" title=\"static\u5909\u6570 - \u7d20\u4eba\u304c\u30d7\u30ed\u30b0\u30e9\u30df\u30f3\u30b0\u3092\u52c9\u5f37\u3057\u3066\u3044\u305f\u30d6\u30ed\u30b0\" class=\"embed-card embed-blogcard\" scrolling=\"no\" frameborder=\"0\" style=\"display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;\"></iframe>","version":"1.0","type":"rich","provider_name":"Hatena Blog","width":"100%","provider_url":"https://hatena.blog","description":"\u732b\u3067\u3082\u308f\u304b\u308bC\u8a00\u8a9e\u30d7\u30ed\u30b0\u30e9\u30df\u30f3\u30b0\u3001148\u30da\u30fc\u30b8\u307e\u3067\u8aad\u3093\u3060\u3002 #include <stdio.h> int counter(void){ static int i = 0; return i++; } int main(void){ int i; for(i = 0;i < 10;i++) printf(\"%d\\n\",counter()); // 0, 1, 2, 3, ..., 9 } static\u5909\u6570\u4fbf\u5229\u3060\u3002JavaScript\u7684\u3060\u3068\u30af\u30ed\u30fc\u30b8\u30e3\u4f7f\u308f\u306a\u304d\u3083\u3044\u3051\u306a\u3044\u306e\u306b\u3002 var counter; (function(){ var i = 0; counter = function(){ ret\u2026","blog_url":"https://javascripter.hatenablog.com/","published":"2008-08-28 22:13:08","author_url":"https://blog.hatena.ne.jp/javascripter/","categories":["c"],"author_name":"javascripter","height":"190","image_url":null}