You should already be familiar enough with Auto Layout to create a user interface with it. So far, we have used Interface Builder to create and modify constraints. But a storyboard is nothing more than a list of instructions that are executed at runtime. It is also possible to create and modify constraints in code. In fact, that is what the layout engine does at runtime.
While I do not recommend creating the user interface of your application in code, it is useful, and at times necessary, to know how to define and add constraints in code. It gives you a better understanding of Auto Layout. At the end of this lesson, you should feel comfortable creating constraints in code.
Read this article on the blog.