![photo](/responsive_image/150/150/0/0/0/cache/matlabcentral/profiles/16003414_1566476157650_DEF.jpg)
Nimra Mubeen
Followers: 0 Following: 0
Statistics
0 Questions
1 Answer
RANK
194,623
of 292,818
REPUTATION
0
CONTRIBUTIONS
0 Questions
1 Answer
ANSWER ACCEPTANCE
0.00%
VOTES RECEIVED
0
RANK
of 19,944
REPUTATION
N/A
AVERAGE RATING
0.00
CONTRIBUTIONS
0 Files
DOWNLOADS
0
ALL TIME DOWNLOADS
0
RANK
of 148,008
CONTRIBUTIONS
0 Problems
0 Solutions
SCORE
0
NUMBER OF BADGES
0
CONTRIBUTIONS
0 Posts
CONTRIBUTIONS
0 Public Channels
AVERAGE RATING
CONTRIBUTIONS
0 Highlights
AVERAGE NO. OF LIKES
Feeds
Write a function called fare that computes the bus fare one must pay in a given city based on the distance travelled. Here is how the fare is calculated: the first mile is $2. Each additional mile up to a total trip distance of 10 miles is 25 cents.
function fare =taxi_fare(d,t) fare=5+(ceil(d-1)*2)+(ceil(t)*.25)
5 years ago | 0