If is a map and if and are paths in with , then .

I was told that this follows directly from the definition of path composition. This is where so the first is a path in and the second is a path in . Is this completely justified by this, or do I need to justify this more than what is above?