Friday, February 15, 2019

Minecraft Curriculum for Teaching Computer Science

I'm not a Minecraft person. I've had the demos. I know that some kids really get into it but … Well, some teachers love it as much as the students. For them it’s probably a great thing if there was some curriculum to use with it.

So, if you do like it and you think it would be motivating to teach computer science using Minecraft for Education there is new Computer Science Curriculum From Minecraft

Thursday, February 14, 2019

US Department of Education Needs CS Experts as Reviewers

I recieved this from Pat Yongpradit of Code.org and thought I should share it.

The US Department of Education has announced the EIR grant competition for FY 2019. This year EIR incorporates an exclusive priority for computer science with a focus on increasing diversity and equity in access, as compared to last year where the highlight was that CS was merged with STEM as a combined priority. See more detail in our blog.

There are many moving parts to the federal grant review and award process, including a merit-based review process. In order to adequately score grants featuring computer science, the US Department of Education must have enough reviewers with K-12 computer science education experience. There is more information on the merit-review process and the Department’s mechanism for selecting reviewers in this blog.

Code.org has been asked to put interested folks in touch with leaders of the EIR grant program. If interested, please send your CV to EIRpeerreview@ed.gov.

Having CS knowledgeable reviewers participating in the federal grant review process is crucial to maximizing the opportunity these grants present the field and our collective goal of expanding access to K-12 computer science.

Monday, February 11, 2019

Programming Has Sure Changed

Last week, I was reading some old code. I wrote it in 1975. It was in FORTRAN IV and it was on punch cards. Really bad code. One character, meaningless variable names. Lots of goto statements. FORTRAN IV didn't have while loops but you could get the same thing with goto if done right.

Someone is probably going to argue that if there are goto statements its not right but it was the only way back in the day.  The famous “GOTO considered harmful” paper had  been written but not universally accepted yet. FORTRAN IV had not adopted language features to make it easy yet.

While I was in university the big new thing was called structured programming. It required some new ways of design and eventually some new programming language features. It took the tools in the languages changed before we could get by without that nasty goto statement.

FWIW I’ve written new version of this program in other languages since and it is much easier, cleaner, self-documenting, and just better across the board with new languages, libraries, and programming paradigms. The basic algorithm is the same though.

The big surprise in my old program was that is was extremely well commented.  The first time I tried to replicate that program in a new language revisiting those comments saved me a lot of time  In fact, one could easily rewrite it in a new language from the comments alone. I could at least feel good about that.

Latter in my career, object oriented programming was the thing. That also required new design considerations and programming language features. FORTRAN IV could not have supported OOP. Today there are versions of FORTRAN (and COBOL too) that have language support for object oriented programming. I’m not sure I want to see them though. Just saying.

I’ve been thinking about what this means for how I teach students today. The rate of change in computing and programming is growing not slowing down. As much as things have changed in the last 45 years they are likely to change even more in the next 45 years.

Some concepts are likely to be around forever. Decisions are likely to rely on Boolean expressions. Repetition is likely to stick around and require proper set up, values to change, and code to check for completion.  We’re going to be thinking about memory and data types even if we don’t think about them in exactly the same way.

John Ruskin said, "For all books are divisible into two classes, the books of the hour, and the books of all time." I first saw that on the library wall when I was in university. The same is likely true if we substitute some software design concepts. Just as monolithic programs gave way to structured programming and structured programming gave way to object oriented programming, programming paradigms change based on changes to language, hardware, and the needs of the day. I don’t really know what changes we will see with quantum programming for example.

What ever programming language we teach with though we need to think about the concepts, especially foundational concepts, that are likely to be around for the long term. I haven’t programmed in FORTRAN IV in decades but understanding how those horrible goto statements mixed with line numbers and if statements worked sure made understanding a modern while loop easy.

Thursday, February 07, 2019

Programming Projects and the Good Idea Fairy

I think Garth Flint (blog at Garth's CS Education Blog) first introduced me to the idea of the good idea fairy. The good idea fairy strikes you with a great idea that works out well (most of the time) but takes you more time to deal with than you first expect. That is probably why you take the idea in the first place.

Well, last semester the good idea fairy visited the idea of a Pez dispenser object  when I was teaching creating of classes and objects in my honors programming class. The implementation was horrible but it did seem to help as one more example. Follow up to a few days ago and the new call for proposals for the annual CSTA conference. What do I have that is a nifty project? I’m still trying to decide what might qualify but the good idea fairy smacked me with the Pez project.

Even before I looked at the old project and realized how bad it was the good idea fairy suggested that a Pez dispenser project really should use a stack object. Well, duh! I and others have been using a Pez dispenser as an example of a stack for years. So that is what I have been working on lately.

I need a Pez candy class first. I think that will be easy for students to design. The data is simple and the methods are few. Then we can design the dispenser class. I think it will be interesting to see how different students design these classes from how I have been thinking about them. I’ll be disappointed if I don’t learn something from them or at least get some ideas for other methods and properties.

I’m constantly trying to think of new projects and improve existing projects. Finding projects that students can relate to, that they can have fun with, and that can really teach to concepts is a never ending task. It’s a task I love though. Wouldn’t it be horrible to teach the same projects year after year? Thank goodness for visits from the good idea fairy.

Monday, February 04, 2019

Supply and Demand in Computer Science Education

We have a supply and demand problem in computer science education. Demand has never been higher and it is growing.  The need is real. Take a look at We need as many Computer Science minors as we need Computer Science majors. by Doug Bergman  (@dougbergmanUSA)

I remember having conversations about increasing CS in middle school and what it meant for high schools. What if high schools had a lot of students wanting to do more CS when they got to HS? We've started building up HS CS but we never really asked what was in university for our HS students who got very interested in CS. Now we have to wonder.

Mark Guzdial @Guzdial) in The growing tension between undergraduate and K-12: Is CS for All, or just those who get past the caps? explains the capacity problem at the undergraduate level. Now not all schools are overflowing and the problem is worse at the “big name” schools. Other schools are likely to stat feeling the pinch as HS CS output increases though.

My understanding is that recruiting more CS faculty in undergraduate schools is even harder than recruiting for HS CS teachers. Maybe because we don't require PhDs to teach in HS?

All levels are faced with the problem of industry "eating the seed corn" by hiring for good pay people who might also like to teach computer science. The TEALS program lets industry professionals teach in high schools and volunteers but I don't see that model fitting in universities.

Universities tend to undervalue industry professionals as instructors and evidence by the second (or third) rate status of adjunct professors and the corresponding low pay. Fixing the shortage of undergraduate faculty is going to cost money at a time when administrators seem all about cutting expenses. Some universities are getting some faculty from industry but since for many people coming from industry it is a life style decision not a monetary decision its unclear how often that will work. And while some industry people make great teachers it can be a hard move for some as well.

My biggest worry is that we’ll get students all excited in CS in high school and they will have no place as undergraduates. Not everyone will or should be a CS major, as Doug points out in his post linked above, but a lot of people will want to take CS as a minor or at least take a couple of courses. How will universities handle this?  It’s going to be interesting.

Friday, February 01, 2019

What is a variable and why is it so hard to understand?

Variables in computer science are complicated. No, really they are. I didn’t consciously  realize how complicated until I read “What is a variable?” on the blog at CACM. Reading that article, which was not an easy read for me, did give me some insight as to why philosophy majors so often make good software developers. I’m not sure I want to have my beginning students read it though. It may leave them with more questions than answers. Maybe in an advanced placement course?

When teaching beginners we need to keep things simple and we have to remember that they don’t have the same base set of knowledge that more experienced people have. So what then is a variable?

A variable name is first of all an identifier. We have lots of identifiers in computer programming. Method names, object names, class names, and variables which are identifiers for something. What is that something?

I like to talk about variables as locations in memory. I used to say boxes but I’m not sure that really works. Students know, or should, that everything is stored in memory as ones and zeros so suggesting a location in memory feels more logical to me. The obvious next question is how big is that location. The answer depends on what is stored in it.

I talk about parking spaces in a parking lot. There are different sizes of spaces: Motorcycles, compact cars, regular cars, and trucks and busses. Spaces are all different sizes and the most efficient use of them is to hold the vehicles they were designed to hold. A motorcycle in a spot for a semi-trailer truck is wasting space. A large truck will overflow as space for a compact car. Size of the memory location depends on what is stored in it. Space can be wasted if a larger space than is needed is allocated.

Size and type are then related attributes or properties of the memory location named by the variable name. So is the variable the location or the name? Does it really matter? Probably if you want to get into the philosophy behind it all but not something beginners are really ready to get into. Maybe it is enough that they know how to declare and use a variable in the first course.

In many ways the first programming course is the hardest to teach and perhaps the hardest for many students to take. Finding that line between deep understanding and too much information to handle at one time is not easy.