The nanodegrees are not that useful overall. What's more important is what you can learn and actually apply/create from there. Just doing the course and slapping on the certificate won't help that much. Also, you'll likely still have to do a lot of self learning beyond the course to really get a good grasp.
But if you want something structured to get started, sure you can go for it. In CS though you can find good resources online for free for almost anything.