UW Home     CSE Home   Announcements    Message Board    Contact Info 

 
 

Python Sessions -- Tuesdays, 3:30-4:20 in EEB 125

Week 9 (Pygame)

  • Lecture Slides: week9.pdf
  • whack.zip
  • Make something cool with pygame!
    Due Saturday, May 30, 11:30pm. No late turnins accepted.

    The assignment: Turn in one compressed file pygame.zip containing all necessary files for your Python game. You will receive the following:

    • 1 extra late day for use on your normal Java programs!

Week 8 (classes, objects)

  • Lecture Slides: week8.pdf
  • point.py
  • bomb.py
  • cities.txt
  • Python Homework 8: Birthday / Date
    Due Saturday, May 23, 11:30pm. Turn in Python 8 here.
    No late turnins accepted.

    The assignment: Turn in two files birthday.py and date.py containing a Python version of your HW8 Birthday / Date program, producing the same output. The rewards you'll get for turning in this program are the following:

    • 1 extra late day for use on your normal Java programs!

Week 7 (lists)

  • Lecture Slides: week7.pdf
  • midterm.py
  • scores.txt
  • underpaid_tas.py
  • hours.txt
  • Python Homework 7: Personality Test
    Due Saturday, May 23, 11:30pm. Turn in Python7 here.
    No late turnins accepted.

    The assignment: Turn in a file personality.py containing a Python version of your HW7 Personality.java program, producing the same output. The rewards you'll get for turning in this program are the following:

    • 1 extra late day for use on your normal Java programs!
    • A super cool snake icon on your Facebook profile, if you use our Facebook application!

Week 6 (file processing, lists)

  • Lecture Slides: week6.pdf
  • input_stats.py
  • carroll.txt
  • hopscotch.py
  • Bonus content (fun file processing example):
  • Python Homework 6: Baby Names
    Due Saturday, May 16, 11:30pm. Turn in Python6 here.
    No late turnins accepted.

    The assignment: Turn in a file names.py containing a Python version of your HW6 Names.java program, producing the same output. The rewards you'll get for turning in this program are the following:

    • 1 extra late day for use on your normal Java programs!
    • A super cool snake icon on your Facebook profile, if you use our Facebook application!

Week 5 (while loops, random numbers, tuples)

  • Lecture Slides: week5.pdf
  • dice.py
  • Python Homework 5: Guessing Game
    Due Saturday, May 9, 11:30pm. Turn in Python5 here.
    No late turnins accepted.

    The assignment: Turn in a file guess.py containing a Python version of your HW5 Guess.java program, producing the same output. The rewards you'll get for turning in this program are the following:

    • 1 extra late day for use on your normal Java programs!

Week 4 (strings, if/else, user input)

  • Lecture Slides: week4.pdf
  • rhyme.py
  • hours.py
  • Python Homework 4: Age Check
    Due Saturday, May 2, 11:30pm. Turn in Python4 here.
    No late turnins accepted.

    The assignment: Turn in a file age_check.py containing a Python version of your HW4 AgeCheck.java program, producing the same output. The rewards you'll get for turning in this program are the following:

    • 1 extra late day for use on your normal Java programs!

Week 3 (parameters, return, math, graphics, parameters)

  • Lecture Slides: week3.pdf | week3.ppt
  • drawingpanel.py
  • Python Homework 3: Cafe Wall
    Due Saturday, April 25, 11:30pm. turn in Python 3 here.
    No late turnins accepted.

    The assignment: Turn in a file cafe_wall.py containing a Python version of your HW3 CafeWall program, producing the same output. The rewards you'll get for turning in this program are the following:

    • 1 extra late day for use on your normal Java programs!

Week 2 (expressions, variables, for loops)

  • Lecture Slides: week2.pdf
  • mirror.py
  • mirror_simplified.py
  • Python Homework 2: Rocket
    Due Saturday, April 18, 11:30pm. Turn in Python2 here.
    No late turnins accepted.

    The assignment: Turn in a file rocketship.py containing a Python version of your HW2 DrawRocket program, producing the same output. As a reference, our sample solution is 42 lines long. The rewards you'll get for turning in this program are the following:

    • 1 extra late day for use on your normal Java programs!

Week 1 (basics, functions)


CSE 142 Python Program

General info about the CSE 142 Python program:

This quarter in CSE 142, we will conduct a special optional program to offer students a chance to learn a second programming language as you're learning Java. The second language's name is Python.

What is Python?

Python is a language that's good for writing programs to process text and other data. It's used heavily in the Linux operating system and at companies like Google.

Why would I want to learn Python, in addition to Java?

Learning two programming languages is a bit like growing up in a bilingual family: you'll not only learn those two languages well, but you may also learn some higher concepts about programming and programming languages in general.

In addition, Python is used in a lot of other fields and disciplines, so it can be useful to have experience in it. Lastly, Python is a powerful language that does a lot of things more easily than Java, so it can be fun rewriting your past Java programs in Python and seeing how much shorter and cleaner they can be solved.

Who will run these sessions? Where will I go, and what will I do?

Our Python program will be hosted by some of our TAs, Kimberly Todd, Craig Kochis and Steve Geluso, under Alan Borning's advisement. Each week, they will hold a 50-minute session to teach you the equivalent of that week's Java course material into Python, along with any related issues.

The work involved in this program would be the following:

  • Going to the weekly sessions
  • Completing optional Python programming projects each week as desired

Primarily, these projects will consist of solving the same problem as that week's Java programming assignment, but in Python, and perhaps with minor modifications to the assignment spec.

What reward do I get for doing this? Do I have to do it?

Participation is entirely optional. The reward for doing these projects will be small, to make sure that these sessions don't give students with prior experience an unfair advantage over new programmers. Right now, we're planning to reward students with 1 free late day for each Python program submitted. No grade points will be added or subtracted in any way for participating in this project.

How do I participate or learn more?

Just go to the next Python session at the time listed above, and if you find it interesting, try writing the Python program given out for that week. If you finish it, you can turn it in from a link that we'll put at the top of this page.

If you want to install and run Python programs on your own computer, follow our Python Installation Instructions below:

Can I still participate even if I don't go to the sessions or cannot make it to the sessions? Can I still come to the sessions even if I don't want to turn in the weekly Python programs?

Yes! If you miss the session, feel free to look at each week's slides and code that we post, and/or still submit the program. And even if you come to the sessions, you don't have to work on the programs we give out; if you just want to come to the sessions and that's all, that is fine with us. It's up to you.