14-5 ��������������?

MATLAB XB⤸]Set Operators^iNVqXAӶiUضXBAOiCpUG

XB⤸
union p
intersect
setdiff t
setxor X XOR
unique Ǧ^̤pĶX]CӤuX{@^
ismember դO_ݩYX

|һpUG

Example 1: 14-MATLABB⤸/set01.mx = [1 2 3 4 5 6]; y = [1 1 5 5 9 9 9]; union_result = union(x, y) % p intersect_result = intersect(x, y) % 涰 setdiff_result = setdiff(x, y) % t setxor_result = setxor(x, y) % XOR B setuniq_result = unique(y) % ۲ ismember_result = ismember(9, y) % 9 O_ݩ󶰦X y union_result = 1 2 3 4 5 6 9 intersect_result = 1 5 setdiff_result = 2 3 4 6 setxor_result = 2 3 4 6 9 setuniq_result = 1 5 9 ismember_result = 1


MATLAB{]pGJg