Vote count:
0
What is de difference between is_a?
and ===
?
Running this Code:
puts myObj.class
puts myObj.is_a?(Hash)
puts myObj === Hash #Curious
puts Hash === myObj
The Outputis:
Hash
true
false #Why?
true
asked 1 min ago
1 Answer
Vote count:
0
===
is a wrapper and can be overridden in subclasses.
answered 7 secs ago
Aucun commentaire:
Enregistrer un commentaire