Was the use of united states military force in Afghanistan in 2001 a justified effective tool to combat terrorism?

Was the use of united states military force in Afghanistan in 2001 a justified effective tool to combat terrorism?