When passing a slower moving car, you only have to pull out and pass the other car. However, when passing a truck, you have to consider the truck's length.
The truck is going to take up more space on the road, so you have to pull out further to safely pass the truck. This means spending more time on the oncoming lane while making the pass.