See this if you're having trouble printing code examples
An Interview with Jeff Elkner
Jeff Elkner is a computer programming teacher at Yorktown
High School in Arlington, Virginia, USA. I met Jeff at the
Python Conference in January, 2000. I was inspired
by his talk, entitled
Using Python in a High School Computer Science
Program because it demonstrated that a high school teacher had begun
delivering on the promise of Python as a first teaching language. He brought
three of his high school students to the conference with him to discuss the
projects they were working on.
Later, at a Birds of a Feather session about the future of Python as a
teaching language for middle school and high school students, Jeff was a
lone, practical representative of classroom experience among a sea of
theorists, professional programmers, computer science majors and (gasp!) even
a book editor. He spoke of ways that teachers could use the methods of Open
Source development to create and share teaching materials that could form the
basis of a new programming curriculum based on Python.
Want to learn more about Python and other open source technologies? Check out
the O'Reilly Open Source
Convention, July 23-27, 2001 in San Diego, California.
I felt strongly that I had to follow up on Jeff's thoughts and asked to
interview him and a couple of his students. I conducted the following
interview in February with Jeff and two of his Yorktown High students, Lex
Berezhny and Virginia Hafer. Lex is a junior intending to take the second
year of computer science next year. He was one of the students that joined
Jeff at the Python Conference. Virginia is a senior; this class will be her
only high school programming course.
- Jeff, what led you to use Python in your first-year computer programming
- We had switched to teaching C++, from Pascal, when the College Board
switched to C++ for the AP exam. I was having a great deal of difficulty
with C++. I was turning off 50 percent of my students. I found myself fighting
with the syntax and I was really frustrated trying to explain clearly what
computer science was about while using a language that seemed to get in the
So I went looking for something else. At that same time, there was a
high school Linux User's Group discussion about
which language was best for teaching programming in a high school. Someone
on that list suggested Python, and over half of the people on the list
jumped in and concurred that it would be the ideal choice for a first
language. That's what led me to investigate it.
- I'm surprised that there was that much awareness of a scripting language
like Python. Do you think the awareness stems from the fact that your high
school is located near Washington D.C., the home of
Guido van Rossum, Python's creator, and the
Center for National
Research Initiatives (Guido's employer and the sponsor of much
Python development)? Or, do you think there are that many teachers across
the country who are aware of Python?
- Most of the participants in the discussion aren't teachers; they are
students. This mailing list is for a high school Linux users' group. Python
comes distributed with Red Hat and most other Linux distributions. So I think
that that crowd is a little more aware of what's going on with Python than
most other folks would be.
Meet Guido van
Rossum, creator of the Python programming language, in a
1999 interview with O'Reilly editor in chief Frank Willison. Guido talks
creation and future of Python, how it fits with other languages, and about
his innovative Computer Programming for Everybody project.
- It seems to me that it's not unusual for students to lead their computer
science teachers into areas where the teachers wouldn't ordinarily go. Linux
is certainly one of those areas. How were you able to persuade your department
and administration to let you use this non-standard language?
- I am very fortunate to have a department head who is supportive of things
like this. She is interested in innovation and in trying new things. I asked
permission from her to pilot it here at our high school, and she readily gave
me that permission. So we're just using it at Yorktown now. I think it's
working out really well, and I'm hoping that we'll be able to extend it into
other schools in the county in the future.
- Are there other instructors teaching the same course with C++?
- So you will then have the ability to compare experiences. Are you doing
any sort of official evaluation, or is evaluation mostly anecdotal?
- It's definitely anecdotal at this point. I'm hoping to talk to Guido
about establishing some metrics as part of his
Programming for Everyone initiative. One useful measure, in a couple
of years, will be the success of students in the AP course because they'll
all be taking the AP exam.
- As I recall from your presentation at the Python Conference, everyone who
goes on to the second year will be taking C++.
- It will be a very interesting measure, then, because what you're really
testing is whether Python or C++ itself is a better introduction to C++.
- Right. I think Python is better.
- I'll be very happy if that turns out to be the case. I'd like to ask Lex
and Virginia a couple of questions. How do you feel about Python? I know you
can't compare it to anything else, but did you find over the year that you
were able to learn programming pretty well? And did you enjoy computer
- I have programmed with several other languages. I started with PHP, which
is a Web scripting language. Then I started playing around with Perl, and
soon after that, I was introduced to Python. At first, I didn't really like
Python because I thought it was too simple. But when I rewrote several Perl
programs in Python, I saw how I could write better and more readable code. I
also noticed how much more concise Python code is and how quickly I could
write large programs.
- It's interesting that you didn't start with Visual Basic or C or any
supported standard language, but with two other Open Source scripting
environments. I would think that you followed an unusual path, in terms of
what a teacher or a book editor would suggest. But I wouldn't be surprised
if your experience is more common for people who are comfortable looking
around on the Web. What drew you to PHP?
- I needed a simple scripting language.
- But how did you come across PHP? PHP is a language that doesn't even have
any good books yet.
- I wanted to build a dynamic website, and I signed up with a service
provider that offered PHP. They also had Perl and a few other languages, but
I thought PHP would be the easiest to learn. They also had a lot of example
PHP scripts. I don't think there's any other language that has so many, so I
started learning PHP from those examples.
- Virginia, how did you get started?
- I began programming when I started the class this year.
- So you've been programming now for about half an academic year. What
interesting tasks are you able to take on with half a year of Python?
- I've been working on a program to list all the wrestlers on the Yorktown
team and maintain a record of their matches. I want it to do some of the
things which Excel does in Windows in terms of maintaining and sorting
- What led you to take computer science in your senior year?
- I hadn't had the opportunity before my senior year because my schedule
was full. Also, my dad really pushed computer science because he thought it
would be good for me.
- Jeff, what aspects of computer science are you able to teach more
clearly now because of Python?
- It's still a little early to tell, but we've completed in half a year
what we used to do in a year. I have been able to teach procedural programming
techniques, introduce students to functions, and get them to use them with a
good degree of facility. We're going to be starting object-oriented
programming in the next couple of weeks.
Virginia is working with a group of students in class who are writing a
Pokemon game program. That idea came out of the discussion at the Python
conference. It's an interesting problem. It's large enough to be pretty
exciting, I think, but still doable. I don't think we could have done
anything like that in any other language.
- So, the fact that Python is fairly abstract and hides a lot of the
details allows people to get real stuff done, instead of getting bogged down
- Absolutely. For example, string handling is a nightmare in C++, while
reading a string and writing it out to file in Python is such a pleasure.
I'm having so much fun with it. It's certainly making programming a lot more
fun to teach.
- I'm interested that there are students like Virginia who are getting
one year of computer science, and will not, through your school, get
instruction in C++. Are you confident, Jeff, that one year of Python
programming will be worthwhile to them?
- I think it will be worthwhile because Virginia is considering a number
of possible futures. For example, she might be a physics major. If she wants
to script an application quickly, using Python will be far more productive
than C++. It is easier to use, so she can get real work done. If she doesn't
go on to major in computer science, she has a tool that's useful to her.
- It does seem like there were a lot of scientists at the Python Conference.
- I'm going to introduce my students to C in the last month of the year
and talk a little bit about gluing the languages together. So Virginia will
get an introduction to C as well.
- That's good. Lex, are you going on to take the second year of
- Is Python a language that you'll continue to use even after learning C++?
- Yes. For example, we're writing a large program called Student
Portfolio [summarized by Lex as an appendix to Jeff's Python Conference
proceedings], and using Python over C++ is a great advantage. I will always
use Python for web applications.
- I recall you mentioning that program at the Python Conference. Is it
going along okay?
- Yes, we have two programmers working on it, Jonah Cohen and myself.
- Is that a database application?
- Yes. We're using PostgreSQL and the PyGresql module. Python is a great
- What about parents, particularly parents who want their child to take
the AP test? Have you gotten any reactions from them?
- My brother took computer science from Mr. Elkner a couple years ago, and
my parents both programmed, so they are pretty familiar with the Yorktown
curriculum. When I went home after the first day of school and told them
that I was learning to program in Python, they were concerned as to how
useful Python would be compared to C++. But they've seen some of the stuff I
do. After all, I've got a web page up, and they don't. So they're fine with
it. They figure everything is all right as long as I am learning to program,
and I am. I'm currently doing stuff that they never did when they programmed
- Jeff, have you heard from concerned parents?
- On Back to School Night, I announced quite loudly that I was going to
be using Python this year, and nobody objected. Actually, I'm pleasantly
surprised that, so far, I have not heard any complaints.
- Jeff, one of the issues that you talked about at the Python Conference
was the need for teaching materials. Can you talk a little bit about that?
What does Python need in order to be useful to teachers who are now using
standard languages like Pascal and C++?
- They need textbooks geared toward high school students, combined with
sample lesson plans and work sheets--the types of resource materials that
exist for all of the other programs that we have at the high school.
- I recall that you are adapting a book for your class's use.
- Yes. I'm adapting How to Think Like a Computer Scientist, by
- Is he allowing you to adapt his book?
- Oh yes. In fact, he's even encouraging me to work on it. It's an
document. It currently uses C++, but
adapting it for Python.
I think we'll be able to overcome the shortage of Python teaching materials
in a very short period of time because we will be leveraging the spirit of the
Open Source software movement. I've already found, coming out of the Python
Conference, a number of people willing to develop and send me material.
Python programmers are used to sharing things, so when they start to create
materials, the culture will encourage them to work together.
- So we can do a sort of Open Source development of educational materials
to support an Open Source language?
- I think that's what we need.
Interested in Python books published by O'Reilly? Check out:
Visit python.oreilly.com for
a complete list of O'Reilly's current Python books, as well as Python
articles and news. And don't miss the O'Reilly Network's
Web site for more Python resources, articles, and development news.
Return to: Frankly Speaking
Copyright © 2009 O'Reilly Media, Inc.