In motor and sensory areas of cortex, neuronal activity often depends on the location of a movement target or a sensory stimulus, with each neuron tuned to a single part of space called a preferred direction (when motor) or a receptive field (when sensory). As we previously reported, some neurons in the monkey prefrontal cortex are tuned to two parts of space, which we interpreted as reflecting attention and working memory, respectively. Monkeys performed a behavioral task in which they attended to a visual stimulus at one location while remembering a second place, and these locations were varied from trial to trial to assess spatial tuning. Most spatially tuned neurons specialized in either attentional or mnemonic processing, but about one-third of the cells showed tuning for both. Here, we show that the latter population, called multitasking neurons, improves the encoding of both the attended and remembered locations. These neurons do so for three reasons: (1) the preferred directions for attention and for working memory usually differ (and often diametrically oppose one another), (2) they have stronger tuning than specialized cells, and (3) pairs of multitasking neurons represent these cognitive parameters more efficiently than pairs that include even a single specialized cell. These findings suggest that multitasking neurons provide a computational advantage for behaviors that place simultaneous demands on two or more cognitive processes.