Header Ads

MATLAB CODE: Program for Age Classification using IF-ELSE-IF Statement ~...

MATLAB CODE: Program for Age Classification using IF-ELSE-IF Statement ~xRay Pixy


Age Classifier in MATLAB

Write a program that ask the user for an age and then classifies the age according to the following scheme:
            0<=Baby<=1<=Child<=Teenager<=18<=Adult<=60<=Senior<120
MATLAB CODE: Program for Age Classification using IF-ELSE-IF Statement ~xRay Pixy

Introduction to Computer Programming with MATLAB: How to use if and else statements to achieve Age Classifier program.
Write a program that asks the user for an age and then classifies the age according to the following scheme.
If-else statement in MATLAB
if{
0 – 1 = Baby 1 – 13 = Child 13 – 18 = Teenager 18 – 60 = Adult 60 – 120 = Senior
} Else
{ Error
}

Program Logic:


2.) MATLAB Assignment Problem: Plot the function f(t) where t having intervals from t = -2.5 to 4. Add a label on the x-axis. Add a label on the y-axis. Add a Title, Add Girds, Change the Color of the graph to something other than blue. https://youtu.be/GLqiIR4q-50

No comments

Powered by Blogger.