Created
October 28, 2009 10:39
-
-
Save vishnugopal/220409 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
>> Kernel.methods - Object.methods | |
=> ["exit!", "chomp!", "print", "fail", "binding", "split", "Array", "readlines", "format", "chop", "iterator?", "catch", "trap", "getc", "putc", "caller", "proc", "chomp", "block_given?", "throw", "p", "sub!", "loop", "trace_var", "syscall", "exec", "Integer", "callcc", "puts", "exit", "load", "lambda", "srand", "global_variables", "gsub!", "untrace_var", "open", "`", "Float", "method_missing", "system", "gets", "sub", "abort", "require", "rand", "test", "warn", "eval", "local_variables", "chop!", "scan", "raise", "set_trace_func", "printf", "fork", "sleep", "select", "String", "at_exit", "readline", "sprintf", "gsub", "__method__"] | |
>> module Kernel | |
>> def iloveyou | |
>> puts "I Love you" | |
>> end | |
>> end | |
=> nil | |
>> iloveyou | |
I Love you | |
=> nil |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
>> module Kernel | |
>> def Array | |
>> nil | |
>> end | |
>> end | |
=> nil | |
>> Array | |
=> Array | |
>> Array 2 | |
ArgumentError: wrong number of arguments (1 for 0) | |
from (irb):20:in `Array' | |
from (irb):20 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment