AbstractWorking memory (WM) is the ability to hold on-line and manipulate information. The prefrontal cortex (PFC) is a key brain region involved in WM, while the hippocampus is also involved, particularly, in spatial WM. Although several studies have investigated the neuronal substrates of WM in trained animals, the effects and the mechanisms underlying learning WM tasks have not been explored. In our study, we investigated the effects of learning WM tasks in mice on the function of PFC and hippocampus, by training mice in the delayed alternation task for 9 days (adaptive group). This group was compared to naïve mice that stayed in their homecage (naïve) and mice trained in the alternation procedure only (non-adaptive). Following training, a cohort of mice (Experiment A) was tested in the left-right discrimination task and the reversal learning task, while another cohort (Experiment B) was tested in the attention set- shifting task (AST). The adaptive group performed significantly better in the reversal learning task (Experiment A) and AST (Experiment B), compared to non-adaptive and naïve groups. At the end of the behavioral experiments in Experiment A, field excitatory post-synaptic potential (fEPSP) recordings were performed in PFC and hippocampal brain slices. The adaptive group had enhanced the long-term potentiation (LTP) in the PFC, compared to the other groups. In the hippocampus, both the adaptive and the non-adaptive groups exhibited increased fEPSP compared to the naive group, but no differences in LTP. In Experiment B, the dendritic spine density was measured, which, in the PFC, was found increased in the adaptive group, compared to the non-adaptive and naive groups. In the hippocampus, there was an increase in mature dendritic spine density in the adaptive group, compared to the other two groups. Our results indicate a role for long-term potentiation and dendritic spine density in learning WM tasks.Significance statementWorking memory (WM) allows for transient storage and manipulation of information and has a central role in cognition. While a great number of research studies have investigated the mechanisms underlying the ‘memory’ part of WM in well-trained animals, the mechanisms that underlie learning WM tasks are not known. Studies have indicated that learning a WM tasks alters and enhances neuronal firing during the delay period, suggesting that long-term plasticity mechanisms could be involved. Our results in this study suggest that learning a working memory task primarily increases long-term potentiation and dendritic spine density in the prefrontal cortex, providing evidence for a role of long-term plasticity processes in learning working memory tasks. Furthermore, learning working memory tasks enhances cognitive flexibility.