Switching between tasks comes with the territory for software engineers. Here are some tactics to help you preserve focus.
Context switching is an unavoidable part of being an engineering leader. It’s a natural side effect of working in a fast-paced, collaborative environment. The good news is that there are simple and effective strategies for lessening the effects of context switching on your focus time.
I’ve had the opportunity to speak with hundreds of engineers and engineering managers and have learned the small things that make a big impact and stick.
Understanding Context Switching
Context switching happens whenever you shift your focus from one task to another. It’s a two-step process.
- Goal shifting: you decide which task you will take on next.
- Rule activation: you adopt the rules of this new task.
Suppose you are coding. You are jumping through your code editor with keybindings.
Now, it’s time for a virtual team meeting. First you make the decision to “goal shift” from coding to the meeting. Next you adopt the rules of this new task by closing your code editor, opening your video conferencing app, and starting a new page in your notepad.
This understanding of context switching as a two-step process makes it simpler to identify areas to reduce the number of switches and to lessen the severity and impact of each switch.
Set clear work priorities
Some context switches are inevitable when working in a collaborative environment. Others are a result of work misprioritization.
When you don’t have confidence that the task at hand is a good use of your time, it’s difficult to get in flow. Instead of diving in, you feel like you should be jumping on to something else, and you feel compelled to rush through your current task. And if you went straight into a task before establishing your priorities, it’s more likely that at some point, something will surface that you deem more important, leading to a switch of context. By getting clear on what your next step should be before starting work, you give yourself permission to dive in.
So, what’s the best way to choose your work?
The best place to start is with a brain dump.
Writing helps clarify your thinking. It makes your ideas higher resolution, and helps you identify what you don't yet know.
Start by jotting down everything on your plate right now. Don’t worry about organizing or being concise. Dump your thoughts freely, without judgment.
Next, create an action list. Select the top 1-3 items from your first list. Remember that each thing you add to your action list takes away from everything else on the list. A shorter list is one you can actually get done.
Now you’re ready to get to work.
Design your work system
There are a few simple changes you can make to your schedule and environment to reduce the need for the Rule Activation step of context switching in many instances.
Design your schedule
Aim to group together tasks that relate to the same people, project, or domain on the same day and in the same block of time.
As a manager, you have 1:1s with reports, cross-team communications, and deep work on strategy initiatives, among other things. When possible, create a schedule where related work falls next to each other. For example, aim to schedule all of your 1:1s on the same day. You’ll enter the mindset of 1:1s and as you switch to each of your reports, you don’t need to activate new rules. Many of the rules of your conversation with your previous report still hold.
If you have a number of topics to sync with your product manager on, aim to do one longer chunk of time together than multiple shorter meetings. You’ll experience more of a continuous conversation and won’t need to do rule activation to change your tone or location.
If you’re involved in multiple projects, prefer to spend one day working on the same project, even if it’s multiple tasks across that project. You’ll already have the rules of this project loaded up in your memory, so you can skip the rule activation step.
Group together short tasks like administrative work or email. Consider creating a designated block of time to address a chunk of outstanding quick tasks. By grouping these tasks together, you prevent them from polluting the rest of the day.
Design your app environment
When you use different applications for a new task or the same task, you need to take on the rules of that app. By unifying your workstation experience across apps, you reduce the need for Rule Activation.
Suppose you’re in your code editor and need to look something up in your notes. You’re used to the rules of your code editor. Your fingers are prepped to use the keybindings of your code editor and the visual layout of your code editor.
If, when you switch to your notes, you need to switch the keybindings that you use, this is a rule adaptation that slows you down. If, instead, you’re able to configure your notes to use keybindings that match the mental model from your code editor, the transition from one environment to the other won’t be as jarring.
Unify color themes
Likewise, imagine your code editor has a dark theme and Slack has a light theme. When you switch to Slack, the color change requires you to readjust and adapt to the rules of Slack. It’s an unnecessary papercut that you likely do many times a day.
By keeping a similar color palette across your apps, you make your experience more uniform and the rules of each app more similar.
Write notes before switching tasks
Writing notes before switching tasks helps you have better closure on that task so that you can be more present for the task that follows it.
When jumping between tasks, it’s common that thoughts from your first task can pollute your focus in your following task. This is called Attention Residue and it can leave you feeling scattered and unable to show up for your team in the way that you want to.
A simple way to reduce the impact of Attention Residue is to jot down a quick Status Dump before switching tasks. The note can be a brief summary that covers what you’re up to and what’s next. It should also include any blockers or questions that will need to be addressed to move forward.
One way to understand why writing notes down before switching tasks is so impactful is to take a look at what happens in restaurants.
Imagine you’re sitting at dinner with a big group. The waiter goes around the table and takes everyone’s order; but doesn’t write anything down. You’re feeling a bit concerned. But then, the dishes come out. Everyone starts eating. And you’re left wondering exactly how your server got everything right.
It isn’t magic. It’s the Zeigarnik Effect.
In 1927, psychologist Bluma Zeigarnik observed waiters in a Vienna restaurant and discovered they were able to retain information about orders as long as the order wasn’t completed. But once the order was communicated to the kitchen, the servers were unable to remember an order.
Zeigarnik identified the tension caused by interruption in further studies. She saw how our brain kept coming back to an unfinished task; holding onto that information and giving us periodic nudges to get it done.
As science journalist Maria Konnikova explained, “our minds want to know what comes next. It wants to finish. It wants to keep working – and it will keep working even if you tell it to stop.”
By writing things down before moving on, you let your mind have some closure so that you can be ready for what’s next.
Context switching is a natural part of collaborative work. By employing strategies around prioritizing work, organizing your calendar, designing your work station, and establishing a notes habit, you can take back more time for focused work.