From: Love U Ruby Date: 2013-03-12T13:17:47+09:00 Subject: Re: Confusion with empty block printing Matthew Kerwin wrote in post #1101134: > I'm pretty sure you want: print( {}.class ) > But that's not what you asked for. > > This is pretty simple syntax stuff. See when typed in IRB the below it gives {}.class #=> Hash And Hans said IRB treat `print {}.class` as `(print {}).class` which causes the output as `Nilclass`. But I was thinking (print {}).class also results `NilClass`. So which is the one IRB actually recognized to give the output `NilClass`. -- Posted via http://www.ruby-forum.com/.