Your SlideShare is downloading. ×
Introductory Programming With Python
Introductory Programming With Python
Introductory Programming With Python
Introductory Programming With Python
Introductory Programming With Python
Introductory Programming With Python
Introductory Programming With Python
Introductory Programming With Python
Introductory Programming With Python
Introductory Programming With Python
Introductory Programming With Python
Introductory Programming With Python
Introductory Programming With Python
Introductory Programming With Python
Introductory Programming With Python
Introductory Programming With Python
Introductory Programming With Python
Introductory Programming With Python
Introductory Programming With Python
Introductory Programming With Python
Upcoming SlideShare
Loading in...5
×

Thanks for flagging this SlideShare!

Oops! An error has occurred.

×
Saving this for later? Get the SlideShare app to save on your phone or tablet. Read anywhere, anytime – even offline.
Text the download link to your phone
Standard text messaging rates apply

Introductory Programming With Python

1,406

Published on

Describes a first year introductory programming course using Python and some of the student outcomes of the course.

Describes a first year introductory programming course using Python and some of the student outcomes of the course.

Published in: Education, Technology
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total Views
1,406
On Slideshare
0
From Embeds
0
Number of Embeds
0
Actions
Shares
0
Downloads
18
Comments
0
Likes
0
Embeds 0
No embeds

Report content
Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
No notes for slide

Transcript

  • 1. Introductory Programming with Python Brendan McCane
  • 2. Hitchhiker’s Guide to Programming
    • Programming is hard. You just won’t believe how vastly, hugely, mind-bogglingly hard it is. I mean, you may think making a decent sandwich is hard, but that’s just peanuts to programming.
  • 3. Donald Knuth says:
    • In fact, my main conclusion after spending ten years of my life working on the TEX project is that software is hard.
  • 4. CS1
    • Average failure rate for CS1 courses is 33% (min 0%, max 60%).
    • Most universities teach Java, C# or C++.
    • Industrially relevant and OO is more “natural” right?
  • 5. Design Principles
    • As simple as possible
    • Few magical incantations
    • Immediate feedback (no compile/run cycle)
    • A practical and modern language
  • 6. Target Audience
    • Students majoring in computer science
      • Python in semester 1 (optional)
      • Java in semester 2 (compulsory)
    • Students not majoring in computer science
      • Mostly science or technical majors
  • 7. Curriculum
    • We modified an open source textbook
    • How to Think Like a Computer Scientist
    • You can download our version from:
      • http://www.cs.otago.ac.nz/staffpriv/mccane/teaching.html
  • 8. Curriculum
    • Introduction
    • Variables, expressions
    • Python builtins
    • Functions (2)
    • Conditionals
    • More functions
    • Test Driven Development
    • Files and modules
    • Iteration (2)
    • GUI programming
    • Case study (2)
    • Strings (2)
    • Lists (2)
    • Tuples and sets
    • Dictionaries
    • System Programming
    • OOP
    • Case study
  • 9. Course Structure
    • Tight integration between lectures and laboratories
    • 24 lectures, 21 laboratories
    • Terms requirement – students had to submit 18 labs (not marked)
    • Labs had basic + advanced exercises
    • Lectures were programming demonstrations
  • 10. Assessment
    • Mid-semester test (20%) – multi-choice
    • Final Exam (60%) – multi-choice
    • Mastery tests (2 x 10%)
      • Programming problems under test conditions
      • Tests published beforehand
      • 4 sections per test, each worth 2.5%
      • Each section pass/fail
      • Graded based on doctests + code inspection
  • 11. Mastery Test Example (lab 9)
    • def score(numbers):
    • """
    • give the average of the numbers excluding the biggest
    • and smallest one
    • >>> score([2, 7, 9, 10, 13, 1, 5, 12])
    • 7.5
    • >>> score([3, 7, 2.5, -4])
    • 2.75
    • """
  • 12. Final Exam Example
    • def matrix_to_sparse(in_matrix):
    • sparse = {}
    • for row_index,row in enumerate(in_matrix):
    • for col_index,val in enumerate(row):
    • if val != 0:
    • sparse[(row_index,col_index)] = val
    • return sparse
    • matrix = [[0,0,1], [0,2,0], [3,0,0]]
    • sparse = matrix_to_sparse(matrix)
    • print sparse[(2,0)], sparse[(1,1)], sparse[(0,2)]
  • 13. Outcomes
  • 14. Outcomes
    • 172 students attended first lab
    • 28% A
    • 23% B
    • 22% C
    • 27% failed (19% failed terms)
  • 15.  
  • 16. Notable Comments
    • Easy topics: first half
    • Hard topics: second half
    • Best aspect: labs
    • I would like to change: “a move away from extensive use of programming”
    • “ F*%! Matrices”
  • 17.  
  • 18.  
  • 19. Statistical Results
    • Java with Python better than Java without (p=0.001)
    • Java 2009 better than Java 2008 (p=0.0007)
    • Java without Python (2009) not better than Java 2008 (p=0.18)
  • 20. Conclusions
    • Python is a joy to teach
    • Learning Python is a good pre-cursor for learning Java
    • Open source textbooks are fantastic
    • Mastery tests are masterful
    • Force students to attend labs

×