``Hasse principle'' for symmetric and alternating groups