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

What the heck?! Watched the first two lectures and then had a look at Assignment 1. It's like the lecturer taught me how to stand on two feet, and the assignment is saying 'Now tap dance in rhythm to the entirety of William Tell's Overture' This is ridiculous! I've read the question by Vegeta and the discussion, but can anyone actually explain how the problem set can be solved using only the basic stuff so far? I think it's absolutely irritating that I'd need to research additional information or ask help from someone to solve something. 'The problem sets will walk us through' MY FOOT!

OpenStudy (anonymous):

You'll be OK, just remain calm and don't panic. The beauty of an on-line course is you can go your own pace. I had the exact same problem. I just kept going with readings & lectures until I felt like I could start on problem set 1. I think I finished the 4th lecture & all the readings up to the 5th lecture before I even tried. If you were a student at MIT, then I suppose you'd have to figure it out. But you're not, so go at your own pace! While you're doing the readings, I HIGHLY recommend that you open python & do all the little exercises you encounter. They're simple and goofy, but you'll get a handle on how Python and the interpreter work. And I think I didn't fully understand how to execute a program in the interpreter until problem set 3.

OpenStudy (anonymous):

That would be fine, but I have OCD, so I think I might have some trouble just 'moving on' and forgetting about PS1 for now. :( It seems everytime I try to take a course, this exact thing happens.

OpenStudy (anonymous):

We had a debate a month or so ago in this group about this issue. Some people said that they thought you should be able to do the problem set with all the information you have learned up to that point. Others (like me) said that you should do the problem set when you feel like you've got enough knowledge to do so. Actually, what I have determined (for myself) after going through about a third of the class is that I'll never really be "done" with any of the problem sets. As I learn more syntax and methods, I realize that an earlier problem could be much better handled than I originally wrote them. So my personal approach has been this: do a problem set. If i get stuck on a part, then I continue with the readings and lectures until I can answer the problem. Once I have gotten the program to run with any kind of success, (no matter how ugly it is) then I move on. When I'm done with the class, I plan to go back and optimize the programs I wrote in each problem set. That would mean remove multiple nestings, combine lines when possible, and some other stuff that I haven't even learned about yet. So if you're requiring yourself to write "perfect" code for every problem set (if that's even possible), then you're doomed to fail. If you can think of the class as *a continuous process* rather than as incremental steps that you complete and move past, maybe you will be less frustrated.

OpenStudy (anonymous):

did you read the reading assignments? This is a college class - i think you ARE expected to do xtra outside of the lectures

OpenStudy (anonymous):

Thanks, for now I'm gonna finish the third lecture and then read all the materials for the first 3, then maybe give the PS a shot. I understand there is no such thing as 'perfect code', but I want to be able to do it without just copying other people's answers and researching. You know, thinking like a computer scientist and doing it myself. I'm still gonna put it out there that it's stupid, the first PS was printing your name, and then calculating the 1000th prime number? is harder than anything I've ever done. (I've done quite a bit of Python before) Pretty dumb.

OpenStudy (anonymous):

hmmm well if you are familiar with python, it shouldn't be too bad - i think that ps is about flow control. don't worry about trying to make it fast/efficient, you can spend a lot of unnecessary time with optimization details. write something that works then see if it is fast enough

OpenStudy (anonymous):

I agree with OP's initial frustration. Problem #1 is owning me. My math theory is admittedly very weak. I feel very lost.

OpenStudy (anonymous):

If you're stuck on a certain part (creating a list, adding to the list, iterating through divisors), then post it & the group can help you through.

OpenStudy (anonymous):

well for this problem and the math - a prime number can only be divided evenly by itself and one. if you divide any other number into it there will be a remainder. you can use this to test for 'primeness' the % operator preforms the modulo operation - this means that it divides the first number by the second number and returns the remainder .... 5 divided 3 equals one with a remainder of two - so - 5 % 3 = 2 6 divided 3 equals 2 with a remainder of zero - so - 6 % 3 = 0 for any number n, n is prime if n % x > 0 - for all x's between 1 and n http://ideone.com/FZZX5 hope that helped

OpenStudy (anonymous):

Can I just add that you only need to check possible divisors of n for all integers between 1 and n/2, as after you get to half of n, nothing after that can possibly be a divisor.

OpenStudy (anonymous):

@Empowers you do know enough to make it work. My guess is that you are trying to do to many things at the same time...

OpenStudy (anonymous):

actually, you only have to check divsors up to sqrt(n) - but that is certainly an optimization. if you spend a lot of time in the beginning trying to optimize, you may find it hard to debug your algorithm.

OpenStudy (anonymous):

@bwCA ('your idea of going only up to sqrt(n)'==brilliant)==True! lol

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!
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!