William toured a Vanguard Class submarine, one of four Trident vessels forming the UK’s nuclear deterrent