For c==4 and other numbers where abs(c)>2, I think the function should be defined to return 0 rather than 1.
I am really stuck on this one. I know it is likley me not the question but I cannot figure out why in the final validation, -2i should give N=1, I get it to be N=2? any help is appriciated, this is the only situlation where code fails.
For people like me that hoped this challenge would end with a pretty picture:
for complex no, u need to take the absolute value to check if it is greater than 2
Broken ink to Cleve Moler's PDF
Thanks for noticing that, @Shlomo Geva. The link has been fixed.
Given an unsigned integer x, find the largest y by rearranging the bits in x
Number of Circles in a Number
Arrange vector in ascending order
Create an n-by-n null matrix and fill with ones certain positions
Area of an Isoceles Triangle
It dseon't mettar waht oedrr the lrettes in a wrod are.
The Goldbach Conjecture, Part 2
Counting in Finnish
The Goldbach Conjecture
Return the largest number that is adjacent to a zero
Find the treasures in MATLAB Central and discover how the community can help you!
Choose a web site to get translated content where available and see local events and offers. Based on your location, we recommend that you select: .
You can also select a web site from the following list:
Select the China site (in Chinese or English) for best site performance. Other MathWorks country sites are not optimized for visits from your location.
Contact your local office