In this study, we analyze a task scheduling problem with small time windows and care workers with different levels of qualification in a nursing home. A set of care tasks has to be assigned to a given number of care workers, so that the total earliness and tardiness from the nursing home residents' preferred time is minimized.To optimally solve this scheduling problem, we formulate a mixed integer program (MIP) and develop a dynamic programming (DP) approach. The numerical analysis shows the reliability of this optimization approach as well as of a heuristic DP approach. A sensitivity analysis with real-world demand data shows the impact of hierarchical qualification levels and large-scale scheduling.