Using matlab Write a function called evenOdd(), that will do the following (YOU MAY NOT USE ANY LIBRARY FUNCTIONS): a. P

Business, Finance, Economics, Accounting, Operations Management, Computer Science, Electrical Engineering, Mechanical Engineering, Civil Engineering, Chemical Engineering, Algebra, Precalculus, Statistics and Probabilty, Advanced Math, Physics, Chemistry, Biology, Nursing, Psychology, Certifications, Tests, Prep, and more.
Post Reply
answerhappygod
Site Admin
Posts: 899604
Joined: Mon Aug 02, 2021 8:13 am

Using matlab Write a function called evenOdd(), that will do the following (YOU MAY NOT USE ANY LIBRARY FUNCTIONS): a. P

Post by answerhappygod »

Using matlab Write a function called evenOdd(), that
will do the following
(YOU MAY NOT USE ANY LIBRARY FUNCTIONS):
a. Places the result of the function in a variable
called evenOddResult, which should start at 0.
b. Accepts two integer parameters called evenNum
and oddNum.
c. Uses a for loop to display the even
numbers from 0 up to and including evenNum. Increment
evenOddResult by 1 each time an even number is
displayed.
d. Uses a for loop to display the odd
numbers from 1 up to and including oddNum. Increment
evenOddResult by 1 each time an even number is
displayed.
Join a community of subject matter experts. Register for FREE to view solutions, replies, and use search function. Request answer by replying!
Post Reply