Error in First Programming Assignment

Hello @Noor_jamali ,

1. I meant just to change xs-nth room, not ys.
Let’s understand the question first.
It written above the cell :

A house has a base cost of 50k, and every additional bedroom adds a cost of 50k. This will make a 1 bedroom house cost 100k, a 2 bedroom house cost 150k etc.

So xs is number of rooms , it will take 1.0, 2.0…it’s correct now.

But ys is cost, where 50k gets added per room.
1 room=100k,
2 room=100+50=150k
3 room=150+50=300k
Hence ys will be what you had done in the begining, in multples of 0.5…that is : 1.0,1.5,2.0…like this.So just change your ys like above.

2.

Hope this clears all doubts!

With regards,
Nilosree Sengupta

1 Like