How did militarism cause world war 1?