How to Solve an equation using if statements?
Ältere Kommentare anzeigen
I am trying to solve this equation. I know I have to write if statements but I forgot how to do it. The equation is : a^4+b^2+c^2=2014 and a+b+c=?.
I know I have to set each variable up an interval.
Thank you.
3 Kommentare
Robert
am 11 Jul. 2015
John D'Errico
am 11 Jul. 2015
Bearbeitet: John D'Errico
am 11 Jul. 2015
WAY more work than is necessary. For example, do you really need to look as far as 100 for a? What is 100^4? Is it considerably larger than 2014?
So is there any reason to look further out for a than floor(nthroot(2014,4))==6?
Likewise, how far out did you need to look at b and c?
Robert
am 18 Jun. 2016
Akzeptierte Antwort
Weitere Antworten (0)
Kategorien
Mehr zu Programming finden Sie in Hilfe-Center und File Exchange
Produkte
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!