Ask your own question, for FREE!
MIT 6.00 Intro Computer Science (OCW) 89 Online
OpenStudy (anonymous):

I just finished PS2a(after a long long time), but just want to make sure it looks right. And if anyone has any input. http://dpaste.com/604150/ Thanks

OpenStudy (anonymous):

I'm still working on PS1, but I'll look at your code after I've moved on to PS2.

OpenStudy (anonymous):

looks good to me ... it produces the correct answer

OpenStudy (anonymous):

Thank you, I worked on that for a while.

OpenStudy (anonymous):

Hi CastorTroy, how did you derive your algorithm? It seems better than mine.

OpenStudy (anonymous):

Hi, sorry for the late reply...I haven't looked at this in a while. I worked for a long time trying so many different ways of solving this problem. First I made a list that puts all the combinations that can be bought into one list. Then, If the number isn't in that list it goes into a second list, which is then a list of all the combinations that can't be bought. it seemed simple after I did it, but I had a bit of trouble with this one.

Can't find your answer? Make a FREE account and ask your own questions, OR help others and earn volunteer hours!

Join our real-time social learning platform and learn together with your friends!
Latest Questions
rose12345: helpp needed
1 minute ago 6 Replies 1 Medal
Aphmau: Hey yall tonight is my concert any advice
3 minutes ago 9 Replies 0 Medals
Pleaseletmeknow: Poem..
39 minutes ago 6 Replies 2 Medals
Stringcheese272: i made a song lmk wut yall think
59 minutes ago 4 Replies 2 Medals
rose12345: there math question
1 hour ago 13 Replies 2 Medals
xcoledd1: help pls
1 hour ago 36 Replies 0 Medals
danielfootball123: HHHEEEELLLLPPPPP!!!!!!
1 hour ago 15 Replies 0 Medals
rose12345: math
1 hour ago 4 Replies 2 Medals
SophiaL: rate
1 hour ago 12 Replies 1 Medal
Can't find your answer? Make a FREE account and ask your own questions, OR help others and earn volunteer hours!

Join our real-time social learning platform and learn together with your friends!