An electronic device supporting a multitasking environment, the electronic device comprising: a communication circuit; a microphone; a display; a memory storing a plurality of application programs; and at least one processor electrically connected with the communication circuit, the microphone, the memory, and the display, wherein the at least one processor is configured to: execute the plurality of application programs, including a first application executed in a background state, and a second application executed in a foreground state; control the display to display the first application in a first window and the second application in a second window; receive a voice input through the microphone; provide the voice input to an intelligent server; receive, from the intelligent server, a path rule associated with the voice input indicating a sequence of actions of an application to perform a requested task; determine, based on the path rule, that the task is to be applied to the first application from among the executed plurality of application programs; determine whether at least one condition is satisfied for changing operation of the first window to the foreground state; when the at least one condition is satisfied, process the task by the first application while maintaining the first window in the background state and maintaining the second window in the foreground state; and when the at least one condition is not satisfied, change operation of the first window to the foreground state and change operation of the second window to the background state, while processing the task to the first window, wherein the at least one processor is configured to communicate with at least one input device, which includes at least one of a keyboard, a mouse, a touch pad, or a touch pen, based on the communication circuit, and wherein the at least one condition includes that a user input from the input device is generated for controlling a function of the second application, during a time period starting when the voice input is generated and ending when the voice input is ended. a communication circuit; a microphone; a display; a memory storing a plurality of application programs; and at least one processor electrically connected with the communication circuit, the microphone, the memory, and the display, wherein the at least one processor is configured to: execute the plurality of application programs, including a first application executed in a background state, and a second application executed in a foreground state; control the display to display the first application in a first window and the second application in a second window; receive a voice input through the microphone; provide the voice input to an intelligent server; receive, from the intelligent server, a path rule associated with the voice input indicating a sequence of actions of an application to perform a requested task; determine, based on the path rule, that the task is to be applied to the first application from among the executed plurality of application programs; determine whether at least one condition is satisfied for changing operation of the first window to the foreground state; when the at least one condition is satisfied, process the task by the first application while maintaining the first window in the background state and maintaining the second window in the foreground state; and when the at least one condition is not satisfied, change operation of the first window to the foreground state and change operation of the second window to the background state, while processing the task to the first window, execute the plurality of application programs, including a first application executed in a background state, and a second application executed in a foreground state; control the display to display the first application in a first window and the second application in a second window; receive a voice input through the microphone; provide the voice input to an intelligent server; receive, from the intelligent server, a path rule associated with the voice input indicating a sequence of actions of an application to perform a requested task; determine, based on the path rule, that the task is to be applied to the first application from among the executed plurality of application programs; determine whether at least one condition is satisfied for changing operation of the first window to the foreground state; when the at least one condition is satisfied, process the task by the first application while maintaining the first window in the background state and maintaining the second window in the foreground state; and when the at least one condition is not satisfied, change operation of the first window to the foreground state and change operation of the second window to the background state, while processing the task to the first window, wherein the at least one processor is configured to communicate with at least one input device, which includes at least one of a keyboard, a mouse, a touch pad, or a touch pen, based on the communication circuit, and wherein the at least one condition includes that a user input from the input device is generated for controlling a function of the second application, during a time period starting when the voice input is generated and ending when the voice input is ended.