2008-11-23から1日間の記事一覧
まんま >> require "rubygems" => true >> require "active_support" => true >> Time.zone => nil >> Time.local(2008).in_time_zone NoMethodError: undefined method `period_for_utc' for nil:NilClass >> Time.zone = 'Tokyo' => "Tokyo" >> Time.local…
まんま import org.apache.commons.lang.StringUtils; public class C2008112300 { public static void main(String[] args) { System.out.println(StringUtils.stripStart(null, "") + "*"); System.out.println(StringUtils.stripStart("", "") + "*"); Sy…
Prelude> :m Text.ParserCombinators.Parsec.Pos Prelude Text.ParserCombinators.Parsec.Pos> initialPos "foo" Loading package parsec ... linking ... done. "foo" (line 1, column 1)
#!/usr/bin/env lua print(pcall(math.abs, -1)) print(pcall(math.abs, -1, 2)) print(pcall(math.max, 1, 2, 3)) print(pcall(string.len, 100)) print(string.len(100)) で、 true 1 true 1 true 3 true 3 3エラーの発生する例を作れなかった…