GRADED ASSIGN. 2 QUE.

154 views
Skip to first unread message

vivek.k...@gmail.com

unread,
Oct 27, 2020, 2:14:47 AM10/27/20
to Discussion forum for Computational Thinking

photo_2020-10-26_16-55-38.jpg


Hello.
In this question in STEP 2, max is initialized to 1.
But if the dataset does not contain any card from SUN GENERAL store, then at the end the highest amount of bill will be shown as 1, which should not be the case.
Correct answer given is f.
It may be b,f both.
Please help.

preeti jyoti

unread,
Oct 27, 2020, 2:18:54 AM10/27/20
to Discussion forum for Computational Thinking, vivek.k...@gmail.com
me to
Message has been deleted

Aravindan P

unread,
Oct 27, 2020, 2:23:47 AM10/27/20
to Discussion forum for Computational Thinking, preeti jyoti, vivek.k...@gmail.com
Hi Vivek,
I thought of the same scenario and got the wrong answer. 
But if we notice the question, it is given "from the Shopping Bills dataset". So I think we won't come across that scenario for this particular question and hence our assumptions that what if there was no Sun General Bill data were wrong.

I hope this clears your doubt

Regards, 
Aravindan

vivek.k...@gmail.com

unread,
Oct 27, 2020, 2:24:05 AM10/27/20
to Discussion forum for Computational Thinking, vivek.k...@gmail.com
***Correct answer given is e.
***And the answer may be 'b' and 'e' both.

Aravindan P

unread,
Oct 27, 2020, 2:26:37 AM10/27/20
to Discussion forum for Computational Thinking, vivek.k...@gmail.com
The answer may be 'b' and 'e' both, only if we assume that the data does not have any cards of "Sun General".
But here the dataset was defined and there were cards of "Sun General". That is why we have got it wrong.

kirti sharma

unread,
Oct 27, 2020, 2:28:38 AM10/27/20
to cs1001-...@nptel.iitm.ac.in, preetijy...@gmail.com, vivek.k...@gmail.com
I'm having same doubt . cs1001-...@nptel.iitm.ac.in   please look into it.

Thanks & Regards

--
You received this message because you are subscribed to the Google Groups "Discussion forum for Computational Thinking" group.
To unsubscribe from this group and stop receiving emails from it, send an email to cs1001-discus...@nptel.iitm.ac.in.
To view this discussion on the web visit https://groups.google.com/a/nptel.iitm.ac.in/d/msgid/cs1001-discuss/8c1c62a1-a25a-4a9c-b2d1-992f6e26d5e4n%40nptel.iitm.ac.in.

Shubham kasyap

unread,
Oct 27, 2020, 2:34:27 AM10/27/20
to Discussion forum for Computational Thinking, kirti sharma, preetijy...@gmail.com, vivek.k...@gmail.com
i am having the same doubt and i want to request all the team members of Computational thinking to go through the all possibility and award us correct marks 

vivek.k...@gmail.com

unread,
Oct 27, 2020, 2:49:54 AM10/27/20
to Discussion forum for Computational Thinking, preetijy...@gmail.com, vivek.k...@gmail.com, paravi...@gmail.com
Hello, this might be correct.
But during the course of the lecture, the instructor has always emphasized on the need to initialize the max or count variable to ZERO.
Hence the doubt.
Thanks.

_Music_Viking

unread,
Oct 27, 2020, 3:53:10 AM10/27/20
to Discussion forum for Computational Thinking, vivek.k...@gmail.com, preetijy...@gmail.com, paravi...@gmail.com
Yes, I even asked this in one of the live sessions. I was advised to initialize max variable to the lowest possible value, i.e., to 0. If it is initialized to 1, if there is a case (as pointed out by Mr. Vivek) where there are no bills generated from sun general, then the result (when max=1) would be 1, which is obviously not possible.
I request the course support team members to look into this issue.

Thank you

Barath Vignesh

unread,
Oct 27, 2020, 4:18:55 AM10/27/20
to Discussion forum for Computational Thinking, _Music_Viking, vivek.k...@gmail.com, preetijy...@gmail.com, paravi...@gmail.com
I also have doubt in this question regarding the same 

Anitta Antony

unread,
Oct 27, 2020, 5:17:34 AM10/27/20
to Discussion forum for Computational Thinking, Barath Vignesh, _Music_Viking, vivek.k...@gmail.com, preetijy...@gmail.com, paravi...@gmail.com
Yes even i hav the same doubt .

Computational Thinking Support 2

unread,
Oct 27, 2020, 6:23:03 AM10/27/20
to Discussion forum for Computational Thinking, Anitta Antony, Barath Vignesh, _Music_Viking, vivek.k...@gmail.com, preetijy...@gmail.com, paravi...@gmail.com
Hi all,
Please go through the pdf as well as video solution uploaded on the portal.
For more clarification about initialization of variables check the tutorial video week 2 Tutorial 2.7.

If you have still doubt write us again.

Thanks and Regards,
Deepak
IITM Online Degree Team

_Music_Viking

unread,
Oct 27, 2020, 12:03:52 PM10/27/20
to Discussion forum for Computational Thinking, ct-su...@onlinedegree.iitm.ac.in, Anitta Antony, Barath Vignesh, _Music_Viking, vivek.k...@gmail.com, preetijy...@gmail.com, paravi...@gmail.com
I went through the solutions, but it doesn't answer the above mentioned situation where there are no bills from a particular store. So if max=0, then it'll cover all possible situations and wouldn't change the outcome either. I initially only had one answer in my mind and after I discussed in one of the live session, i changed my mind and also included step 2 in the answer. I lost marks because of this.
Please clarify this.
Thank you

Reply all
Reply to author
Forward
0 new messages