Skip to main content
Journey Uncommon Logo
JourneyUncommon
hardRubymethod_missing dispatch internalsSingle-choice MCQ

Why does `respond_to?` return `false` for a name that `method_missing` successfully handles, and what hook fixes it?

class Ghost def method_missing(name, *args) "ghost:#{name}" end end p Ghost.new.respond_to?(:anything)