Wednesday, July 12, 2023

Thoughts on CSTA Conferences Past and Present

I am attending the 2023 CSTA Conference online. I’m not writing blog posts about it the way I normally do. Lots of reasons for that but I will post some learnings from it later. I am downloading lots of presentation slides as notetaking.

But I wanted to take a few minutes to ramble about what has been going through my mind as I watch. One question I get a lot is: Why are your as a retired person still attending CSTA conferences and events. It’s a fair question. It's not as if I have a classroom in the fall to apply what I learn.

The truth is that the computer science education community has been a big part of my life for a long time It started online in listservs even before I was blogging and a while before there was a CSTA. It’s a part of my life that has spanned jobs – teaching and otherwise. I’d like to think I still have things to contribute. And personal value to gain. The conference bag on the right, from the CS & IT symposium in 2005, was not my first conference BTW. But I found it today and thought I’d add it.

The community started small. By the second or third conference it seemed like everyone knew everyone. That was good in some ways but for CS to grow the teacher community had to grow. Now I go to conferences and there are many people I don’t know. And others from the  past have retired and chosen not to be active anymore. I don’t blame them BTW. We all make the choices for how to spend our time and energy.

The growth has been good. Many on the current CSTA board have been members for only a few short years. They bring energy and ideas and innovation that is necessary for the future of the organization. They still listen to us old timers though. I am on the conference committee for next summer’s CSTA conference. I am excited about that work. So many new things in our field. So many new and diverse voices that we need to hear from.

Speaking of next year, the call for proposals for the 2024 CSTA conference is now open. I encourage anyone with interesting ideas to submit a proposal. The CSTA audience is the best and most responsive audience ever. It’s going to be in-person next year. Start hitting your school/district up for funding to attend. It can be life and career changing.

Tuesday, June 06, 2023

Conversations on AI in Education

Pat Yongpradit from Code.Org tweeted an image of what they are seeing in conversations about AI and Education. (The link on the image below goes to that tweet)

Now I am not having the detailed conversations with policy makers that Pat is but these boxes pretty much match what I am seeing in my social media these days. That bottom right hand box is where I’d like to see myself and others but it feels like people in power are more on the left hand column.

The usual tech bros are touting the AI can replace teachers line. We’re a long way from that and I am not sure we’ll ever be at a point where that is a good thing.

Lots of teachers are afraid of cheating. That’s not an unreasonable fear. There are pundits, some of whom are teachers, saying “just change the way you teach and all will be well,” I see a shortage of detailed information about just how to teach differently to avoid AI cheating. I think some of those people are fooling themselves if they think they have all the answers. Students are very good at finding new ways to cheat no matter what the assignments are.

The right hand column is where I think we need to be but there are more questions than answers there. Frankly, I think the technology is still to new and experience with it is to little to answer these questions with any strong level of confidence. We really need teachers to experiment with these tools in actual classrooms. That takes some freedom that doesn’t exist in as many places as we would like. Government and administrators in too much of the US are more interested in constraining what teachers do in the classroom than giving teachers freedom to develop new ways to teach.

The question is, are schools going to still look the way they did 100 years ago, as they do today, or are we going to see real change that uses technology to the fullest?

Monday, June 05, 2023

Let’s Try it and Find Out

Facebook memories reminded me of a frequent conversation I had with students. They would ask me what would happen if they tried something and I would answer “I don’t know. Let’s try it and see.” Students often expect teachers to know everything. Well, if they believe their teacher is a real content knowledge expert. Of course there is more to be known than can ever be known. This is especially true in a subject like computer science.

Too many students expect teachers to find answers to questions they have. That’s not the best way for them to learn. Trying things for themselves is a lot better. That’s why I loved to suggest that students try things for themselves. Encouraging students to try things for themselves and to experiment helps them grow more independent as learners. It also helps them develop their creativity.

This is similar to another exchange I used to have with students. I might say “One of us should look that up. You’re the student so I think it should be you.” Again, students who look things up for themselves remember information better,

Thursday, May 25, 2023

Coding With AIs Prompts Are Important

Last night, when I could not sleep, I got up and wrote some code. I added some features and data checking to my Wordle solver helper program. When I finished I felt good about my work and myself. I think that made it easier to get to sleep and I slept well.

It got me thinking this morning. When I was in university and still learning how to code I would occasionally get frustrated and feel less confident. So I would write some simple program to help me feel like I could actually code. I must have written code to display the multiplication table from 1 times 1 to 12 times 12 at least once a semester. It worked for me.

Now that is a trivial program but it involves nested loops (for me anyway) and I am not sure I would assign it to students today. It’s really a meaningless program in today’s world when everyone has a calculator app on the phone they don’t leave the house without.

I did wonder how an AI would write the code. So I opened the chat option in Bing and asked it “Write some C# code to display multiplication tables in a list box” It gave me some code that displayed this:






Not what I wanted at all. The problem is ambiguity! So I tried again with “Write some C# code to display the multiplication table from 1 times one to 12 times 12” and got this:

Not what I wanted either. So I specified at grid format “Write some C# code to display the multiplication table from 1 times one to 12 times 12 in a grid format”

This reply required a dataGridView object and the program did not work. Looks like I need to set up the dataGridView object in ways the AI did not explain. Now there is a problem worth thinking about. I asked Bing what settings I needed for the dataGridView and it gave me several. Program still did not work. At this point I gave up on the dataGridView option. It sort of feels like overkill anyway.

So I tried another prompt “Write some C# code to display the multiplication table from 1 times one to 12 times 12 in a grid format in a list box”

Finally I got what I wanted even though I am not thrilled with the formatting.

I’ve got a number of takeaways from this. Yes, students could use  these AI tools to get code for typical school assignments. On the  other hand, I think it would be fairly easy to tell when they do. The use of features that are not typically covered in class lectures or demos would be one clue.

It’s not always easy to provide the right prompts to the AI. Sometimes it takes some iteration. I think though, that teacher have to reduce ambiguity in assignment descriptions in many cases. Arguably some amount of ambiguity is helpful to allow for creativity. It can be a fine line,

As noted, I didn’t like to formatting so I did modify the code to get closer to what I wanted. I think programmers are going to be needed in a lot of cases to finish off what AIs generate. Both providing the right prompt and finishing off will be important skills for some time to come. Finishing off is going to require some serious skills in many cases BTW. Programming is not dead yet.

Saturday, March 18, 2023

Finding Words With All The Letters Programming project

Does anyone else lay in bed in the morning thinking about coding projects or is it just me? I’ve been playing around with a Wordle solver helper for a while now. It helps me find words based on what I know after each guess. One of the things I like to do is see how many possibilities there are based on different hints. Yesterday I had most of the letters but not in the right place. So this morning I was wondering about words that had the same letters but in different orders. Seemed like something I needed to write some code about.  

A key method is to compare all the letters in one string with the letters in a second string. At least the way I was thinking of handling it. It struck me that that is a great assignment for students. I don’t have any students handy so I asked ChatGPT to write that function. This is the prompt I gave it:

Write a C# function that accepts two strings and returns true if all of the letters in the first string are included, in any order, in the second string. Return false if any of the letters in the first string are not included in the second string.

That is a lot like what I would assign a student. ChatGPT gave me some very nice code. It wasn’t exactly like what I was writing in my head. It used foreach and ToCharArray which is probably the best and easiest way to do this. I was coding before either of those became common so my mind goes to for and while loops and the string SubString method. This was a good reminder for me.

I left the rest of the program, which wasn’t a lot of code, to myself.

Once written I had some fun with it. For example, the letters in Alfred also makeups the word flared. The letters in face are also used in café. Some groups of letters do not make up any words of course, This seems like it could be a fun project to give students. It was fun enough for me.

Tuesday, March 14, 2023

Book Recommendations for CS People

tl;dr Book recommendations:

Overnight Code was recommended to me after I recommended Code Girls on Facebook. Overnight Code is a truly inspiring story of a woman with two strikes against her (female and Black) whose hard work, determination, and talents helped her do some revolutionary work in naval engineering and integrating hardware/software systems.

Debugging code is arguably a lot harder than writing new code. Raye Montague was amazing at debugging code and integrating disparate systems. But also a good person who helped mentor and advance others. She was given tasks that others had said were impossible to complete. Talent and hard work (Raye had a lot of both) allowed her to accomplish beyond expectations.

There is a lot of good career and life advice woven into this story as well. Advice for everyone. I could have benefited from this book early in my career.

"Code Girls: The Untold Story of the American Women Code Breakers of World War II"  was recommended by several people in a Facebook group dealing with a Kindle Challenge that Amazon is running. The idea about code breaking sparked my interest right away. This book was more than just that though.

There were plenty of insights into code breaking but the look into the lives of these amazing women was the highlight. It was a different time and women would not as respected as they should have been. Yet, these women put their considerable talents into working for the war effort and their country.

Code breaking is a fascinating subject in itself of course. I enjoyed reading about the “bombe” machines, how they were created and used. I also found the difference that code breaking made in the conduct of the war (World War II) to be interesting. This is not the sort of thing many history courses cover.

It’s easy to label these books as books for Women’s History Month or the Raye Montague book as being for Black History Month but that would be a mistake. These are books for all year long. I recommend them to anyone interested in the progression of computing in society. Code Girls is a great read for cybersecurity or cryptography students. Overnight Code is a powerful read for anyone not just computer science people. It is just that inspiring.

Thursday, February 23, 2023

Does It Run in the IDE?

I was reading a tweet from a person saying they lost points a program written with pen and paper because the teacher thought the code would not run. When the student asked the teacher to write the code on the computer it ran.

The Twitter discussion was on the wrongness of code assignments on paper but I am not sure that paper coding assignments are necessarily wrong. I suspect that the problem in the Twitter user's case may have been a teacher who is experienced. I could be wrong of course.

The real problem is a teacher putting too much faith in their own mental execution of the code on the paper. I have found it a good practice to enter code I was the least unsure of into an IDE and run it on the computer. I’d almost always check code I thought did not work. Students can be very clever and write code that doesn’t look like it will work but does work. Or code that does look like it works but doesn’t.

This all points to problems with testing computer programming in general. Writing code for evaluations is problematic in a number of ways. Yes, I know the AP exams do it that way. I’ve only graded the AP A exam once but I can tell you it’s not that easy. Handwriting can be hard to read for starters. I’ve already mentioned how clever students can be. I loved the 10 line code answer for a guestion that was looking for a one line return statement. I could have saved myself a lot of time if I could have verified it by running it.

Asking students to write code in an IDE offers logistical issues for starters. There is also the issue of students being able to look at each other’s screens and sharing files. Some object to students using autocorrect, error checking, and help files. All the sorts of things professional developers use. Some teaches do prefer code turned in electronically because it allows for auto graders. I’ve discussed them here several times. Basically, mixed feelings.

Evaluating student knowledge is one of the more difficult tasks programming teachers. It’s a problem with no easy answers. For now, I think, the best policy is to use a variety of assessments.

Tuesday, February 14, 2023

People Are Bad At Giving Instructions

One of the things that make me sure that programming will be around for awhile even with better and better artificial intelligences is that people are bad at giving instructions. Well, that may be unfair. They are reasonably good at giving instruction to other people but that is not the same as being good at giving instruction to the literal minded.

The most famous instruction, I first heard it from Grace Hopper almost 50 years ago is the instruction for using shampoo “Lather, Rince, Repeat.” There is a lot left out there. Most obviously, repeat how many times? It also doesn’t say if one should wet their hair first. In computer terms, an infinite loop without setting initial conditions.

I recently bought a new cover for a light switch. The first instruction was to turn off the circuit breaker for the switch. Good advice. On the other hand, the instructions did not say to reset the circuit breaker when finished installing the cover. A literal minded installer would never have a working switch.

Of course, people figure these things out. We are aware of the larger context and are good at filling in missing pieces. Computers are not that good at any of this.

Part of what we teaching when teaching programming is how to give instructions. Not just how to translate those instructions into code but to fully understand and describe the steps needed to complete at task. I believe these are necessary skills. I think they will translate to other fields. Not that I have proof but it seems logical. In any case, we’re going to have to get good at giving instructions if we are going to tell AIs what code  to write.

Sunday, February 12, 2023

CS Students–Learn Your IDE

Eugene Wallingford had a great post on WHAT WHAT DOES IT TAKE TO SUCCEED AS A CS STUDENT? It’s got a lot of good advice and I recommend it to students in high school or university. For now I want to focus on one or two pieces of his advice. Specifically, “Get to know your programming environment”

For the most part, in class, teachers have time to do an introduction to the development environment but not much more. We run through “Hello World” or similar to walk students though creating a project entering code, and running their first program. That;s all we have (or perhaps all we make time) for.

Typically there is a lot more to a development environment than what we show students. Even a simple IDE like IDLE for Python or Visual Studio Code has a lot or options and functions we don’t go over in class.

Students who spend some of their own time exploring their development environment are going to have an easier time though out their course. Indeed, throughout their CS career.

Related to learning your development, Prof Wallingford suggests keeping your IDE open while reading through textbooks or other resources. That lets one more easily try out code examples while studying. That goes a long way towards understanding what one is reading. When I review textbooks or other teaching resources I always run the code examples for myself. In part , to see if they are correct of course but also to see for myself what students will see and learn from the example.

Writing code that is not specifically assigned for a course is always a help for learning. If a student takes the time to experiment with a project of their own interest they will do far better in the course they are taking.

Friday, January 27, 2023

Rhode Island Computer Museum

I spent some time looking at the Rhode Island Computer Museum web page today. A lot of interesting stuff. Some great information under the Education and Activities page. If you teach the history of computers this is a great resource with text and pictures.

The Collections gallery has a huge collection of images and descriptions of items they have as well. Check it out at Home (ricomputermuseum.org)

Monday, January 23, 2023

What Jobs Are Safe From Automation?

“It's tough to make predictions, especially about the future.” – Yogi Berra

That doesn't mean people don't try. Recent advances in Artificial Intelligence have a lot of people predicting what jobs are an are not likely to be replaced by computers. Technology is challenging the ideas about what jobs can and cannot be replaced by technology. Doug Peterson, who shares a lot of interesting articles, recently share this one predicting that leaders will not be replace. It's an optimistic article. 5 Reasons Leaders Shouldn't Worry That Generative A.I. Will Take Their Jobs | Inc.com

A lot of jobs we once thought were completely safe are being seen in a new way lately. AIs are creating what looks to many like art for example. This is forcing us to take a hard look at how we define art. Some recent visits to museums had me already asking “what is art?”

Today we joke about AI attempts to write short stories, poetry, and other narratives. A lot of our stories in movies an even books are formulaic. How long before AIs can write Hallmark Christmas movies I wonder? What used to be a joke may be a prediction of the future.

A lot of people are speculating on  the future end of the programmer profession. People have been predicting that would decades but we are closer to that than ever before. Software developers today think they are safe though because they (we) know that end users are terrible about describing what they want a program to do. Will the future bring courses and training on how to talk to AIs? Possibly. I can sure see the need for it.

People who are not teachers are suggesting that AIs will take over for human teachers. As someone who spent 15 years teaching I am not so sure about that. I think the human touch will remain important for the future. Teaching is a lot about reading people and establishing relationships. Wil AI be able to do that? I am not sure anyone knows.

One area I think people have an advantage over AI is that we are bad with risk analysis. What may seem like a flaw leads people with some luck, some imagination, and some hard work to beat the odds. We see potential needs when a pure look at the data would not see anything. And we are often willing to defy the odds for things we believe in. I am not sure AI will get there.

Thinking about the possibilities of AI and what it means for the future of work is a critical topic. It’s something we need everyone, but especially students, to be thinking about.

Saturday, December 31, 2022

Looking Back and Looking Forward in CS Education 2023

Traditionally I write a year end look back on thee previous yest in CS education. (Last year at Looking Back on Computer Science Education in 2021) Honestly, that post would largely work for 2022 as well. I attended SIGCSE, CSTA, and the New England Regional CSTA conference. They were all great. There was good learning at all of them. But new stuff? Not a whole lot. A few new tools. Some new robots. Some new AI and cyber security curriculum. But really not a whole lot.

I think we’re in for some disruption in 2023 though. Tools like ChatGPT and GitHub CoPilot are probably only the first of tools that are going to shake things up in teaching programming. Are we even going to still teach programming in computer science? If not, what will computer science courses look like? If we are still teaching programming how will we do it? What will it be all about?

We’re still going to see a need for teaching about cybersecurity for sure. Artificial Intelligence is also going to be more important. We’re seriously going to have to think about how we teach about it. We have to include not just how it works but how it should be used. Ethics in computer science has never been more important.

The discussion about ChatGPT and what it means for education in general and CS education in particular is going to be ongoing. We have to reink how and what we teach. It’s going to be an interesting year. Have you been thinking about it? What are your thoughts so far?

Note: I highly recommend Mike Zamansky's blog post at Kicking off 2023

Monday, December 19, 2022

Thoughts on Optimization of Code

Donald E. Knuth famously said "Premature optimization is the root of all evil." The important word there is “premature.” Optimization is not a bad thing. It isn’t always required though.  The joke is that a programmer will spend hours coding a solution to a problem that can be solved in minutes manually. Is that a bad thing? It really depends on the circumstances. If one is getting paid by the hour one could easily argue that it is wrong. On the other hand if time is not really the issue and writing the code is fun – why not?

There have been times in my career when optimization has been very important. I helped spec a computer for high speed/bandwidth data collection. It was critical that the computer be able to take the data and place it in memory without losing data. We actually analyzed the speed of various machine language instructions for optimization purposes. That’s pretty exceptional of course.

I also remember writing a program of my own that took what seemed like a long time to process some data. I thought about trying to optimize it but as often as the program was to run it would not have been a good use of my time. Before I ran it again I got a new computer which made a bigger difference in execution time than I would probably have been able to get though “fixing” the code.

Old habits from the days of slower computers stick with me though and I tend to think a lot about code execution. Recently I had ChatGPT write some code for me (Coding with ChatGPT–Armstrong Numbers) I looked at the code very closely since I was trying to come to some conclusions about how good the code was. I noticed that the C# version it gave me was highly dependent on modulus and division which are somewhat time consuming compared to addition and multiplication. The program I write didn’t use any modulus or division but a lot of multiplication and addition. Both used the same number of raising to a power of 3 so it doesn’t play an important role in performance differences.

Having some time on my hands, I added some timing code to see if there was a difference. My program turns on to be much faster. Yea me. Of course both execution times are very small fractions of a second. Does it make sense to optimize this code? Probably not in this case. In fact, I would argue that the most understandable code may be a better goal for this project. That is a very subjective goal. Different people might come to honest but different conclusions.

Another goal might be scalability – the ease of adapting the program for other Narcissistic numbers. The ChatGPT probably wins there.

SO much depends on what we want to optimize:

  • Speed of execution
  • Ease of understanding
  • Ease of enhancement/modification
  • Possible other considerations(?)

Getting all three may not always be possible. It’s an interesting question though and one developers do need to ask.

Saturday, December 17, 2022

Coding with ChatGPT–Armstrong Numbers

Trying out ChatGPT seems to be all the rage these days in certain geek circles. I may even be late to the game but I tried a few things over the last couple of days.

I started with one of my favorite little projects. Armstrong numbers are a form of narcissistic  number which is a number that is the sum of its own digits each raised to the power of the number of digits. I first wrote a program to calculated these as an undergraduate when I wrote programs for it in about a half dozen different languages.

I fed in the following prompt using C#, Visual Basic, and Python as the programming language.

Write a [programming language] program to calculate three digit numbers were the sum of the cube of each digit equals the original number.

The results for C# and VB were the same algorithm written in the specific syntax. The Python code was slightly different. You’ll probably not be surprised that the code ChatGPT showed me is very similar, if not identical, to code examples you can find with Google or Bing.

The C#/VB plan depends highly on integer division and the modulus operator to break down the number into its digits.

for (int I = 100; I < 1000; I++)
{
     int sum = 0;
     int temp = I;

    while (temp > 0)
     {
         int digit = temp % 10;
         sum += digit * digit * digit;
         temp /= 10;
     }

    if (sum == I)
     {
         Console.WriteLine(I);
     }
}

The Python sample changes the integer into a string and used that to address the individual digits.


for num in range(100, 1000):
   # Convert the number to a string so we can access each digit
   num_str = str(num)
   # Initialize a sum to store the sum of the cubes of the digits
   sum_of_cubes = 0
   # Iterate through each digit in the number
   for digit in num_str:
     # Convert the digit back to an integer and add the cube of it to the sum
     sum_of_cubes += int(digit) ** 3
   # If the sum of the cubes is equal to the original number, print it
   if sum_of_cubes == num:
     print(num)

Note that the Python example nicely includes comments. A dead giveaway that a student didn’t write it. All samples come with simple explanations of how the code works. The explanations tend not to be very deep so oral questioning of a student would probably still show if the student understood the code or not.

It looks like, for some simple, student exercises can be solved by ChatGPT. It is not much different from doing any other online search for the most part. How worried should teachers be about ChatGPT especially? I’m not sure. Cheating goes on all the time and there is a lot of sample code already out there for many common assignments. It’s going to be a bigger problem for educators who have very large numbers of students who can’t be familiar with the code their students write. Or who can’t ask them questions to make sure they understand what they turn in.

I think I would ask ChatGPT to solve some of my assignments before I assign them just so I know what sort of answers I might see.

Side note: Neither of the ways ChatGPT suggested is the way I solve this program. There are more than one ways to skin this cat.

Sunday, December 04, 2022

When Computers Write Code

For most of my career I hive been hearing that some day computers will write all the code and human programmers will no longer be needed. Or at least, not as needed as today. Are we getting close to that time – finally? And if we are what does it mean for teaching computer science?

Recently, the CS education world has been discussing GitHub Copilot.

GitHub Copilot uses the OpenAI Codex to suggest code and entire functions in real-time, right from your editor.

While some of the discussion has been about the suit against Copilot (GitHub Copilot litigation) much of the discussion has centered around what it means as a tool for cheating by students. More recently there has been some visibility to the use of ChatGPT to write answers to programming questions.

For example, this year’s Advent of Code seems to have been “invaded” by ChatGPT climbing the leaderboard by answering the problems is seconds. (Adventures With ChatGPT: Advent of Code Edition | Tabs, Not Spaces) Of, perhaps, even more concern to teachers, ChatGPT seems to be somewhat satisfying as a solution to Advanced Placement Computer Science A questions. (ChatGPT passes the 2022 APCSA free response section)

I’d be very surprised if students are not already using these tools. This brings up several questions. One is - how do teachers keep this from happening? We probably can’t. So how do we detect when it does happen? Do we use these tools ourselves to see what sort of code is generated for our assignments? Seems like yet more work for people who don’t have enough time as it is.

Another question, which students are sure to ask, is what is the purpose of students writing code that artificial intelligence can write easier and faster? If you read the article above about putting the APCS A questions through ChatGPT you’ll see that the results are not prefect. So for the time being it looks like good programmers can still write better code than the AI. How long that will last is anyone’s guess. If history is any guide, it will not last long.

I remember when optimizing compilers started generating more efficient than the world’s best assembly language programmers could write. It was painful for some and a real boon for others. It didn’t completely do away with the need for assembly language programmers but it did reduce the need.

What do we tell students who ask “what’s the point of learning to code?” My thought is that we talk about the need for human oversight of AI generated code. We need to verify that it works as we want it to work and that means we need to understand code. We’re also going to need to fine tune generated code for some time to come. Understanding code will also help write good instructions for the AI that generates code. Again, understanding how code works is important for that.

Of course, there is a lot more to computer science than just writing code. Programming languages are the language of that study. Learning assembly language still helps people understand how computers and computing works. So will learning higher level languages.

The AIs will get better. Our conversations with students will get harder. Cheating is always going to be a challenge. We live in interesting times.

Friday, December 02, 2022

Adventures in Taking Code From the Internet

Facebook memories remined me that ten years ago I was thinking about writing a program that would ring bells (nautical time) on the hour and half hour. I didn't write it back then. Probably because I was busy with my day job. It got me thinking about writing one now just for the fun of it.

Now I have written a fancy clock program before. It looks something like this.

That was written in Visual Basic and I really wanted to use C#. Besides that, that program is a bit busy for something as simple as I wanted to write. The Timer and DateTime classes in the .NET Framework make writing a simple clock application very easy. I thought I would take a look on the internet to see what code samples I could find. There are plenty of them. I found several interesting looking samples that also drew analog clock faces.

The first one I found (C# Analog Clock Program (thecrazyprogrammer.com)) looked simple enough so I created a project and copied the code into it. It was broken. Looking back at the comments on the original post I found a number of comments saying the codebase broken. None of them had answers.

That seems to be pretty common. No doubt that things worked fine for the original coder but something was lost in the posting. I suspect that most people who come across this sort of thing are beginners which would explain the questions. Having a bit more experience I quickly fixed the errors I had and got the program to work. It didn’t look quite like I wanted but again, having enough knowledge to understand the code without a lot of comments, I made some adjustments and got it looking the way I waned.  I suspect that many beginners would either life with it or try a whole lot of things until they stumbled on the right combination. Or maybe broke the program beyond fixing.

That highlights one of the big issues with beginners taking code from the internet. Without some real knowledge even minor issues will keep success away from the student.

I found a second project that was put on the internet some years after the first one I found. Interestingly enough, it appeared to be a refactoring and modest improvement over the first one I found. The code was nearly identical. No credit was given to a previous coder. In fact it was so close that I copied a snippet and pasted into the earlier project. With a tiny edit (a name change) it worked perfictly. This is what I wound up with.

The Code Project web site has a variety of analog clock code samples. I took at look at one - Analog clock control in C# – CodeProject that was pretty good. and worked more or less right off the bat. Except that is was written in a much older version of Visual Studio than I was using. (2003 compared to 2022). An upgrade was required with Visual Studio handled pretty well. That is not always the case if coders used depreciated or removed features or changed names. Yet another issue with taking code from the internet.

Well, now I have a couple of code samples to play with. Most of all I am more convinced that actually getting code from the internet to work can be more complicated than many would think it is.

Now to think about ringing bells. Which reminds me of one last story,

Back when I was in college during the mini-computer era we had a lab full of ASR-33s. They had actual bells that were hit with a little hammer. One student wrote a program that ran in the background of the computer and "grabbed" control of each terminal as it became available. Then it would start ringing all the bells at once. It so happens that when it ran the only one in the lab was the computer department secretary.

The department chair held a meeting with all the TAs and it never happened again.

Saturday, November 12, 2022

CSTA New England Regional Conference #cstaNE2022

This year’s CSTA New England regional conference is at the University of Massachusetts (Amherst) school of Education. It’s a great venue. There are around 150 people here. I can remember when CSTA national conferences were smaller than that. It just shows the growth in CSTA and the growing strength of CSTA chapters over the last several years.

I am running into a number of people I know and meeting some new people as well. That is what makes in-person conferences so extra special.

The energy level is high here with teachers from all over New England and New York. The opening keynote was by Dr. Cheryl Swanier who talked about “Changing the Face of Technology for Social Good.” Tech has a woman problem – we don’t have enough of them. As part of her talk, Dr. Swanier showed this video Girls in Tech for Web Summit - Ruthe Farmer – YouTube We’ve been taking about this problem for a while but we really need to take our actions up a notch. The case is pretty clear.  Dr. Swanier also talked about explicitly teach problem solving. Much as we’d like to think that teaching programming does that, the truth is that it has to be taught explicitly.

My first regular session was “Teaching with Minecraft: Education Edition.” You’d think I would know all about this but honestly I have trouble grokking it. My grandson has seen it and thinks its cool so I figured I should learn more about it. Minecraft Education requires a license. That may limit what I can do initially. However, it looks like there are a lot of resources for teachers including lesson plans, the ability to share worlds, create NPCs (non player characters), and portfolios. There are Code Builder options for blocks, Python, or JavaScript with MakeCode.There is a demo that can be used with “An Hour of Code” and I will play with that. I was pretty impressed with what I saw today.

There were 10 or 12 exhibits at the event. One that really interested me was the Kibo robot from Robot Kits For Kids | KIBO | Kinder Lab Robotics.

These robots are programmed with blocks. Not virtual blocks! Physical blocks that cane be connected together. Once the program blocks are together the bar codes on the blocks are scanned into the robot which will execute the program This looks pretty interesting.

After lunch, we had a panel of CS/STEM leaders from the New England departments of Education reporting on what progress the states have made in the last few years. The tl;dr of it is that there are been a lot of progress. But the efforts could really use more money. States have created certification programs, made progress in getting states to require schools to offer CS courses. We’ve still got a long way to go. We could use more money for teacher PD. We could require CS courses for graduation. Although in several states CS courses can count for graduation credits in various ways.

Next up for me, Kathy Kleiman, Founder of the ENIAC Programmers Project, who told the story of the women behind the ENIAC. A story I have heard before but Dr. Kleinman tells it really well. I loved that she talked about the history of these women after the war. A lot of information at ENIAC PROGRAMMERS PROJECT

Next up for me, Gencyber Teacher Academy @ the Univ of New Haven: Incorporating Cybersecurity Concepts into 9th-12th High School STEM Curriculum.

This program includes a week long summer "camp" and follow up virtual sessions. Last year the program just included 25 teachers from Connecticut but applicants from other states are welcome to apply for next summer.  Anyway, it comes with a stipend and some good free stuff. And a lot of good learning,

Last regular session of the day for me, Bring Computation to Life with the micro:bit. I love the Micro:Bit and always like to learn about how teachers are using them in their classrooms. I linked to the presentation above and on slide 7 you can find the mini project that opened the session with links to the code used. It uses the ability of the Micro:Bit to send and receive messages. You will find a lot of useful links on that slide deck including in the speaker notes.

The closing plenary involved a lot of recognition of CS teacher award winners. and door prizes!

Next year the conference will be on October 20, 2023 at the University of Connecticut Storrs. Should be a good one.

Tuesday, October 25, 2022

The Computer Science Professional Development Problem

Mike Zamansky is stirring up trouble again. OK not really his intent I’m sure but people can get defensive. I have to say that I agree in principle with most of his post at Why PD doesn't work for CS

Mike lists four different types of PDs.

  • Teachers sharing practices
  • conferences and meetings that teachers choose to attend
  • PD run by content providers, that is, people selling something
  • PD required by schools and districts

It’s as good a break down as any though the fourth kind can really include any of the first three. So I will zero in on those for now. Full disclosure: I have given all three of those types of PD in my time. This includes working for a content provider, Microsoft in this case, that was more or less selling something even though the stuff I was presenting to teachers was free.

I think that these types of PD can be great things for improving a teacher’s knowledge and skills. None of them are really good for starting from scratch.

Teachers sharing practices is a wonderful thing. At least if the audience has a solid base to start. We see a lot of it in social media. Not as much on blogs as I would like but still some valuable stuff is shared on Facebook and even Twitter. I have learned a lot from teachers sharing practices. I hope I have helped some teachers as well. Short bursts of knowledge is not a foundation to start a CS teaching career on though.

Conferences are wonderful. The sessions are short, typically 45 minutes to an hour and a half. They are great for sharing and for helping teachers to build on existing knowledge or to lead them in new directions for further exploration. But one should not expect a new to CS teacher to attend a conference (or two) and expect them to be a trained teacher.

PD run by content providers are typically longer form. Usually a week, sometimes two. These can be awesome especially if they are given to educators who have prior experience For example, a teacher who has taught simple web page building attending a session of a more advanced toolset for a more advanced course. Or a teacher who is learning a new programming language who can relate it to previous knowledge. These sorts of PD can be a mixed bad of course. Some focus totally on the tool and not much of pedagogy. Others are concept focused as much a tool focused. Regardless, these can be very valuable especially when the content provider is a non-profit with goals beyond selling product.

We’re getting to an interesting point in the development of CS for All. We’re rapidly outgrowing the availability of strong technical CS educators. Qualified CS teachers are hard to find. We’re not doing students any favor by putting untrained or antiquatedly trained teachers in the classroom. Colleges and universities have been complaining about having to reteach students who were poorly taught in high school for years. Do we really want to see more of that? I think not.

We really need more long term training for CS teachers. We’re starting to see some programs and more universities are developing CS education research programs and working with schools of education. That really needs to ramp up. States have to start requiring more training for CS teachers AND put some money into making it happen.

Friday, October 07, 2022

Micro:Bit Programming for Grades K to 3 With #MicroCode

The Micro:Bit is a pretty cool piece of hardware being used in a lot of schools. It’s mostly used in middle school and above but that may be changing. New from Microsoft is Microcode beta. Programming is via a MicroCode web editor at aka.ms/m9. Microcode documentation is at Microsoft MicroCode for micro:bit (beta)

Take a look at the intro video below.People who have used Kodu Game Lab will see some simularity in MicroCode. Although the graphics are very different, the programming modularity is similar. With both, programming is drag and drop using cute little kid friendly icons.

Besides the Micro:Bit itself, Micro:Code supports Jacdac devices which opens a lot of new prossibilities. I wrote about JacDac back in July - Jacdac and Micro:Bit 2.0–First Look.

I haven’t tried this with my 8 year old grandson yet but I hope to soon. I think he’ll like it.

Wednesday, September 28, 2022

How Far We Have Come With Programming Languages

Last night I had a dream during which someone suggested that COBOL would make a good first programming language. They tried to promote the data division and English language syntax as plusses. When I shared this on social media it got a lot of laughs. Few would take this as a serious idea and with good reason.

We used to joke that the hardest part of programming in COBOL was learning how to spell environment. (You had to be there) But really that data division was a bear to get right. The cognitive load was a lot for beginners. Today they are some who think that static variable declarations are enough cognitive load to hold students back and COBOL was a lot of effort.

COBOL is still around and I understand that it has changed somewhat. I thought that “Structured Programming in COBOL” (there was such a book) was a stretch but object oriented  COBOL just boggles my mind.

Most of the people in my age group in the industry have some experience with COBOL. For more than a few it was the first or second or, as in my case, third programming language. Learning multiple programming languages was a big thing early in my career. FORTRAN, COBOL, BASIC, and C (before C++)  were all a part of many people’s tool box. I worked on one project that had code in all four of those languages plus PASCAL.

Today we have a lot of new languages. C++. C#, Java, JavaScript, Rust, and I could go on and on. Today’s languages have more and more powerful decision structures, looping structures and libraries that do things for us that we used to have to program ourselves. We have improved error handling, the ability to use classes and objects, and many other cool features. That doesn’t even touch on powerful IDEs and the ability to compile and get results in seconds rather than hours and days.

With power often comes complexity. Complexity means cognitive load and potential for confusion and errors. We walk a fine line determining what to teach and how to prevent students from getting overloaded. It’s an exciting time to be teaching for sure.