matlab yi dao wen ti~ Thank you!Write a program that would take an integer number from the user and output to the screen all possible triplet combinations that would multiply to the given number.Each set of three numbers (triplets) should appear only

来源:学生作业帮助网 编辑:作业帮 时间:2024/05/07 08:13:45
matlab yi dao wen ti~ Thank you!Write a program that would take an integer number from the user and output to the screen all possible triplet combinations that would multiply to the given number.Each set of three numbers (triplets) should appear only

matlab yi dao wen ti~ Thank you!Write a program that would take an integer number from the user and output to the screen all possible triplet combinations that would multiply to the given number.Each set of three numbers (triplets) should appear only
matlab yi dao wen ti~ Thank you!
Write a program that would take an integer number from the user and output to the screen all possible triplet combinations that would multiply to the given number.
Each set of three numbers (triplets) should appear only once. This means that for a correct answer the user will not see both outputs “5 3 1” and “3 5 1”. Your program should include the set of numbers 1, 3, and 5 only once. Here is an example for finding all the triplets that will multiply to 24.
This is a solution for 24!
1 1 24
1 2 12
1 3 8
1 4 6
2 2 6
2 3 4
After each trial, the program should ask the user if they would like to continue. If the answer is “yes” the program should repeat. If the answer is “no” the program should say goodbye and exit.

matlab yi dao wen ti~ Thank you!Write a program that would take an integer number from the user and output to the screen all possible triplet combinations that would multiply to the given number.Each set of three numbers (triplets) should appear only
程序如下:
str='Yes';
while strcmp(str,'Yes')==1
n=str2num(input('Please input a number: ', 's'));
for i=n:-1:1
for j=1:i
for k=1:j
if n==i*j*k
disp([k j i])
end
end
end
end
str='';
while strcmp(str,'Yes')==0 && strcmp(str,'No')==0
str=input('Continue?','s');
end
end
disp('Goodbye!')

yi tian ky ti wen ji ge wen ti da ge ,wo de dian nao ye yu dao zhe ge wen ti,du wo yi sha guo ,ying gai shi wen jian shun huai le. matlab yi dao wen ti~ Thank you!Write a program that would take an integer number from the user and output to the screen all possible triplet combinations that would multiply to the given number.Each set of three numbers (triplets) should appear only wo zen me kan bu dao wo de wen ti a ,pao dao na qu le bu zhi dao ji zi chu le shen me wen ti dian nao gao shou jin lai kan kanjian pan an jian quan luan le,xuan ze wen jian tu biao shi shubiao yi dian,yi da pian wen jian quan bei xuan zhong guan yu mai che de wen ti .wo 19 sui .xiang mai yi liang che lian lian shui ping ,jia ge yao qiu zai 10W yi nei(shan dong qing dao di qu) .er qie yao qiu shi shang,nian qing yi xie de .yi shou er shou ju ke .ma fan da jia le .wo de dian nao da bu lia wo yi tian nen xiang ni ti ji ge wen ti ? lai dao zu qiu qu ,wo bu zhi dao gai ti shen me wen ti hao,wo gai zen me ban? da bu liao zi~HELP~wo ke yi qie huan shu ru fa ,yu yan lan ye neng kan dao ,yong ke niu cha ye mei wen ti,ke jiu shi da bu chu lai zi~ctfmon.exe wo ye you jiu ming a .wo xia zai N ge le ,suo you de shu ru fa wo dou shi le yi bian ,meiyong yi kai ji jiu chu xian zhe yang de wen ti anna dao ci yi wen yi ge wen ti?wo mai lao yi zhang di guo shi dai 3 di you xi guang ban zen me quan shi ying weng di ya bu zhi dao ji zi chu le shen me wen ti ,jian pan an jian quan luan le,xuan ze wen jian tu biao shi zhong wen yi han wenni xian zai bu zhen xi wo .you yi tian wo zhen de bei ni qi pao le,ni xiang zhao wo ye zhao bu dao.qing bang wo fan yi cheng han wen. mei you wen ti mei you wen ti mei you yi wen yi dao hua xue ti氢气与氧气生成水正电极反应方程式电解液是KOH溶液