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

ps11: can someone post a solution through problem 3? My implementation of updatePositionAndClean(self) is pretty dense and I have a bug I can't figure out. code here: http://codepad.org/DZR49b59#comment-bdYKRDeo There's a while loop in lns 234-268 that is pretty dense, but that doesn't seem to be the problem. I posted the output in a comment at the bottom of the page.

OpenStudy (anonymous):

figured it out -- my code breaks if a robots position is at 0,0 or max,max. Is there an easier way to do what I'm doing in the while loop?

OpenStudy (anonymous):

actually, i'm not sure that's the problem. There was a problem where a robot could be initialized to position 0,0 or max,max, but I took care of that and I'm still getting errors that the program tries to set the robots position outside of the room

OpenStudy (anonymous):

this guy posted complete solutions. I working on PS11 myself, so I haven't looked, but his solutions to other problem sets have been very good (I think he's a professional programmer ... which would explain why they're so good). https://github.com/sebrenner/Mit-6.00-OCW-Problem-Set-Solutions#readme

OpenStudy (anonymous):

hmmm, i moved, if it wasn't in the room i kept changing directions till it was in the room, then cleaned it. http://dpaste.com/705243/

OpenStudy (anonymous):

thanks!

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
xcoledd1: I made a song, I want to know what I need to fix.
28 seconds ago 11 Replies 0 Medals
Coyote: Finding central angle measure
11 minutes ago 26 Replies 0 Medals
luvnickk: If yalll fw the weeknd your a 10 !!
31 minutes ago 15 Replies 3 Medals
Ash2746: Anyone know anything interesting about the Cold War?
1 hour ago 11 Replies 2 Medals
Austinsbabygirl4life: Texas schools look funn
1 hour ago 6 Replies 2 Medals
chuu: Is it (Hunt 30-31) or (Hunt 30-1) in MLA?
3 hours ago 1 Reply 0 Medals
luvnickk: what typa music yall listen to ?
1 hour ago 28 Replies 3 Medals
GothgirlLillian: Is music considered art?
2 hours ago 8 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!