Using nested if structures write a MATLAB script that will t

Using nested if structures, write a MATLAB script that will take the patient\'s temperature (in degree F) as keyboard input from the user. If the patient\'s temperature is higher than normal (> 98.6), display The patient has a fever! and ask the user to input (at the keyboard) the patient\'s white blood cell count (in leucocytes/microliter). Then, if the white blood cell count is greaterthanorequalto 10500, display the message Antibiotics should be prescribed!; otherwise, display the message Take two aspirin and call me in the morning.

Solution

temp=input(\'enter temperature in °F\');
if(temp>98.6)
fprintf(\'the patient has a fever !\');
count=input(\'enter white blood cell count in leucocytes/microliter : \');
if(count>=10500)
fprintf(\'antibiotics should be prescribed\');
else
fprintf(\' take two aspirin and call in morning...\');

 Using nested if structures, write a MATLAB script that will take the patient\'s temperature (in degree F) as keyboard input from the user. If the patient\'s te

Get Help Now

Submit a Take Down Notice

Tutor
Tutor: Dr Jack
Most rated tutor on our site