Ruby - Modules and Mixins
What is the main effect of using
prepend with a module in Ruby?prepend with a module in Ruby?prepend inserts the module before the class in the method lookup chain, so module methods override class methods.include, which inserts the module after the class, prepend places it before, changing method resolution order.15+ quiz questions · All difficulty levels · Free
Free Signup - Practice All Questions