Jump to content

Requoter

Members
  • Posts

    5
  • Joined

  • Last visited

About Requoter

  • Birthday 07/08/1982

Retained

  • Lepton

Requoter's Achievements

Lepton

Lepton (1/13)

10

Reputation

  1. I have an assignment where I'm supposed to implement a simple vacuum cleaner agent with a randomized agent function. Basically there's a world with 36 rooms in a 6 x 6 grid. The vacuum cleaner determines which square is it in and whether there is dirt in the square. It can choose to move left, move right, suck up the dirt, or do nothing. I'm new to python and I'm having really hard time to figure out what to do and how to do this. This is all I've done so far and I kind of have a mental block on what do do next. Specifically how would I implement the simulations of sucking dirt or perform the movements left, right, up, or down. If anyone can push me in the right direction I'd appreciate it. # vacuum cleaner DIRTY = '*' CLEAN = '#' NUM_ROOMS = 36 room = ['*', '*', '#', '#', '*', '#', '#', '#', '*', '*', '#', '#', '*', '#', '#', '*', '*', '*', '*', '*', '#', '#', '#', '#', '#', '#', '*', '*', '*', '#', '*', '*', '#', '#', '#', '*']
  2. I'm new to Python, and while doing homework I got stuck on this little problem. We were supposed to output various sequnces of numbers using for loops and range functions. I did all of them except the last one which I can't figure out. How do you output the following sequence: [1, 2, 6, 24, 120, 720]?
  3. In my uni C++ is about the only language they focus on. They don't even teach Java yet some professors still require you to write programs in it.
  4. Thanks Pangloss. I was kind of thinking the same thing you said. It's just one of the reasons I've been losing confidence is that it seems I'm the only person in both classes who's having troubles with the material. That's why I felt really lame. On overall I'm doing better in this class than OS fundamentals, but writing a final project in LISP is something I don't think I can handle.
  5. I'm a computer science major and this is my junior year and up until now I didn't have any troubles with courses I took. So far I've had two courses of Problem Solving with C++, Assembly Language, and Data Structures, I've made A's on all of them. But this semester I've been taking Operating Systems and Artificial Intelligence and this stuff just seems over my head, I'm studying really hard, but I don't understand the material, especially in OS class. My average from tests and projects in both classes is a borderline between C and D. I'm thinking what if the rest of the courses are going to be even harder than this? Should I start thinking about changing my major or try and stick with this one?
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.