tirthajyoti-ghosh/Enumerables

my_all? method remarks

Closed this issue · 0 comments

  • From line 42 to line 45, the logic is that, if the parameter given is a Class (if param.is_a?(Class)), then true/false if n.class <= param)

  • For line 38, the logic is:
    image

  • For line 47 & 48, the logic is that if the param passed is a Regexp (if param.class == Regexp), then check if n.match?(param). There's no need to create a new Regexp instance.