Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

MATLAB help! Homework 6-Conditionals Function Name: bachelor Inputs 1. (double) 1x2 vector of the minimum age and maximum height in inches, in that order 2.

image text in transcribed

MATLAB help!

Homework 6-Conditionals Function Name: bachelor Inputs 1. (double) 1x2 vector of the minimum age and maximum height in inches, in that order 2. (char) Information about potential bachelor contestant Outputs 1. (char) A string indicating whether or not the contestant will be on the Bachelor Background You feel like you've tried everything to find true love: you've joined new clubs, talked to random people next to you in class, and even switched majors from CS! As you sit alone on your couch scrolling through television channels, you come across the show The Bachelor and realize this is the perfect opportunity for you to find true love! Desperate to make it on to the show, you decide to watch old seasons to determine any similar characteristics of previous contestants. You then decide to write a MATLAB function to figure out your own chances of making it onto the show Function Description Write a function that takes in information about a potential contestant and outputs a string stating if they made the show. A contestant's application data will be in a string containing the following characteristics in this order, with each response separated by commas: ,KAge>, , ,, First, set a minimum age and a maximum height standard, specified by the first input. Anyone who does not meet these standards will automatically not be considered. A contestant's height is given in feet and inches formatted as such '- separated only by a single dash. If the contestant meets these two conditions, then they must either have a MATLAB coding ability score greater than 7 or be from Atlanta. If, however, the contestant's name is Amanda', they automatically make the show regardless of age and height. After analyzing all these criteria, output a string based on the result: will be on the next season of the Bachelor! OR Sorry, > result bachelor( [21, 70], 'Demi , 23,5-2,Dallas,Interior Designer,8') - result'Demi will be on the next season of the Bachelor! Notes: . Atlanta may be referred to as 'Atlanta', 'ATL' or 'Atlanta GA The test cases given are not exhaustive. Be sure to test all possible conditions

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Beyond Big Data Using Social MDM To Drive Deep Customer Insight

Authors: Martin Oberhofer, Eberhard Hechler

1st Edition

0133509796, 9780133509793

More Books

Students also viewed these Databases questions

Question

Discuss how selfesteem is developed.

Answered: 1 week ago