<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def ncores_reserved(self):
 """ Returns the number of cores reserved in this moment. A core is reserved if it's still not running but we have submitted the task to the queue manager. """

        return sum(task.manager.num_cores for task in self if task.status == task.S_SUB)