Problem 43708. Replace all odd numbers with NaN
Replace all odd numbers in the vector or matrix with NaN. For example, if
x = [1 3 4 5 8 11];
then return
y = [NaN NaN 4 NaN 8 Nan];
Solution Stats
Problem Comments
-
9 Comments
FYI: https://au.mathworks.com/matlabcentral/answers/350695-how-can-i-delete-a-comment-on-a-submission-on-file-exchange
@David I agree with you that there is no dedicated channel for reporting Cody bugs, and your idea of Cody-specific discussion forum is awesome. The unable to "delete", unable to "unlike" are longstanding bugs for more than a year now. I hope this should catch the Cody term's attention.
FYI (again), in lieu of a proper forum, occasionally there are some interesting discussions in the Problem Comments sections of individual problems. An example is https://www.mathworks.com/matlabcentral/cody/problems/2959-divide-by-4 . They are, however, extremely difficult to find. Regards, DIV.
Solution Comments
Show commentsProblem Recent Solvers79
Suggested Problems
-
Find the sum of the elements in the "second" diagonal
1159 Solvers
-
Basics: 'Find the eigenvalues of given matrix
423 Solvers
-
The Answer to Life, the Universe, and Everything
544 Solvers
-
Switch matrix to a column vector
360 Solvers
-
07 - Common functions and indexing 3
417 Solvers
More from this Author7
Problem Tags
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!