Art can occur when the same person is both the source of the requirements for the program, and the implementor of the program. Much of the art is in the coming up with the specification: that is the concept in the art.  The concept can be skillfully rendered into code.  Concept + skillful rendering = art.