What's faster, comparing 2 strings (pre-saved strings representing the names of the objects for example), or comparing a typeof their objects?
In my list, I have doors and normal nodes; Thinking about how to actually save them, in a form of a string or each one as class instance into the list. I just need to detect wether the current index is a door or a regular node.
What would you say?
Thank you!
↧