This study investigates dynamic system-optimal (DSO) and dynamic user equilibrium (DUE) traffic assignment of departure/arrival-time choices in a corridor network. The morning commute problems with a many-to-one pattern of origin-destination demand and the evening commute problems with a one-to-many pattern are considered. Specifically, a novel approach to derive closed-form solutions for both DSO and DUE problems is developed. We first derive a closed-form solution to the DSO problem based on the regularities of the cost and flow variables at an optimal state. By utilizing this solution, we prove that the queuing delay at a bottleneck in a DUE solution is equal to an optimal toll that eliminates the queue in a DSO solution under certain conditions of a schedule delay function. This enables us to derive a closed-form DUE solution by using the DSO solution. We also show the theoretical relationship between the DSO and DUE assignment. Numerical examples are provided to illustrate and verify the analytical results.