2009-04-01から1ヶ月間の記事一覧

ブロックとイテレータ

a = [3, 2, 1] a[3] = a[2] - 1 a.each do |elt| print elt + 1 endh = { :one => 1, :two => 2 } h[:one] h[:three] = 3 h.each do |key, value| print "#{value}:#{key}; " endまつもと, ゆきひろ = Flanagan, David 「1.1.2 ブロックとイテレータ」『プロ…

「Virtual Server 管理 Web サイト」が IE8 で操作できない件について

「Virtual Server 管理 Web サイト」が IE8 で操作できない件について。

ブロックとイテレータ

ruby -e "1.upto(9){ |x| print x }"まつもと, ゆきひろ = Flanagan, David 「1.1.2 ブロックとイテレータ」『プログラミング言語 Ruby 』 2009年1月 オライリー・ジャパン isbn:9784873113944 p3 広告 Ruby

ブロックとイテレータ

ruby -e '3.times { print "Ruby ! "}'まつもと, ゆきひろ = Flanagan, David 「1.1.2 ブロックとイテレータ」『プログラミング言語 Ruby 』 2009年1月 オライリー・ジャパン isbn:9784873113944 p3 広告 Ruby

イテレータと yield

using System; using System.Collections; using System.Collections.Generic; public class Program { /// <summary> /// このプログラムのメイン・エントリポイントです。 /// </summary> public static void Main() { // 列挙可能な文字列を生成します EnumarableStrings str…

イベント、デリゲート、ラムダ式

using System; public class Program { /// <summary> /// このアプリケーションのメイン・エントリポイントです。 /// </summary> public static void Main() { // イベントハンドラを宣言 EventHandler handler; // イベントハンドラをラムダ式で生成 handler = (sender, e) =…