Would probably learn it from the elves as well.  Elves have a natural sense for finding hidden doors, and being rangers and of the woods would mean that survival was based on knowing things like whether food was spoiled or what was worth money so they could trade better at the local market.