This chapter presents a dynamic field theory (DFT) of executive function (EF), the collection of processes and mechanisms that give rise to flexible or goal-directed behavior. The chapter highlights autonomy, a central challenge in the study of EF. Response selection based on stimulus-response associations learned through task instructions is used to illustrate the approach. First, the chapter explains how DFT can account for the emergence of response selection abilities in the context of switching between tasks early in childhood. It then investigates how DFT can account for changes in response selection over practice in the context of simultaneously coordinating and executing two tasks in adulthood. Across these examples, the chapter highlights how two-dimensional fields can implement fast and flexible learning of tasks (associations between stimuli and responses) and how interactions among components of an architecture can give rise to rule-based behavior. Specifically, flexible rule-use emerges from interactions between different levels of representation, including feature-specific representations and dimensional level representations.