Unfortunately, coding can be a non-productive use of time. If you're not taking active steps against it becoming so, it is probably a non-productive use of time. This is one of the core insights of the Lean Startup folks that is valuable to all of us: building stuff does not necessarily move the needle for the business, and the difficulty of building stuff bears no relation whatsoever to the business benefits realized by building it.
Sometimes I wonder, though, if methods like Lean Startup aren't solidifications of this very illusion: that just building something awesome and slightly gonzo is too much fun to be trusted. Lean Startups tend to miss things people don't know they want, or that yield negative results when market-tested with crappy prototypes. It's like "Design by Focus Group". It's probably safer. The success rate is probably higher. But I think you pay for it in loss of craziness. At any rate, startups either don't need to hear this, or shouldn't listen to it.
If something is hard to build, it's probably going to be more scarce. That would tend to make the thing more valuable. Your point is good, but "no relation whatsoever" seems a bit too strong.