Skip to main content

How Does It Work?

I've always been interested in how things work. As a young person I took apart my fair share of toys, plants, and household appliances to see how they worked. Most of the appliances and toys I also put back together, but not always. I learned from these experiences and as I grew older I was the fixer in the house. I remember installing a phone jack in the house around 7th grade so we could get rid of our old rotary dial telephone and move to the modern era with a touch tone phone! A lot has changed in the last 40 years.

As a computer programmer and now as a Computer Science Professor I understand the value of learning how things work.If we understand a tool, we are more likely to use that tool to its fullest extent. We also have a much better understanding of what went wrong when the tool breaks or when we don't use it correctly.

Programming languages are one of the main tools of computer programmers. I have spent a lot of my career understanding programming languages and how they work. A couple of years ago I developed a framework for teaching the implementation of programming languages. Part of that project included building a virtual machine. A virtual machine is a computer program that simulates a computer in some ways but also provides a higher level of functionality than the bare hardware of the machine. This virtual machine was written using C++ and was called CoCo. I was happy enough with CoCo but I knew it lacked some features that I really would have liked to include in its implementation.

Sometimes when you build something new and start using it, you learn enough about it to see its flaws. I decided that CoCo could be written and implemented more effectively in Java. In January of this year I recruited a student, Jonathan Opdahl, to work with me and we began rewriting CoCo in Java, naming it JCoCo. The implementation is now complete, better than CoCo, and available at http://cs.luther.edu/~leekent/JCoCo. Jon and I learned a lot about virtual machine implementation and coding in Java as a result.

One of the cool things about CoCo and JCoCo is that they include a tool called a disassembler, which like its name suggests, lets us take apart programs to see how they work. This particular disassembler takes apart Python programs so you can see how they are implemented. And, if you need to further see how it works, you can look at the JCoCo code which will soon be available on the web at http://github.com/kentdlee/JCoCo. The ability to write a program, and then to take it apart and peer into its low-level implementation details makes learning how Python works so much easier. In my Programming Languages course students go on to use the knowledge of how Python works to implement other programming languages. By applying what they learn, students are able to concretely see it in practice, making their level of understanding that much deeper.

This process of prototyping leads to discovery which leads to better implementations. It happens all the time in computer science where one implementation is replaced by a new and improved version. The key is to not be afraid of making changes, but to make those changes in an informed and responsible way.

The key to being a great programmer is related to these ideas. Great programmers aren't afraid of trying new things. They aren't afraid of saying when they don't know how to do something. They learn from their mistakes but aren't afraid of making them either. But, they also want to take it apart and see how it works.

These ideas can apply to all of us as well, not just programmers. Sometimes we venture down a road that seemed to be a good idea, but when we start living it we discover there are flaws that we would like to fix. In life the key is also to be brave and not be afraid to make changes in a responsible way. Periodically doing a life assessment is a good thing. I think we should all take a look at our lives once in a while and decide what is going well and what is not. Making actual changes in our lives is hard. And, we don't get to prototype our lives and then start over. So the choices we make in our lives are a bit more important than deciding which programming language to use.

Life is all about the relationships we have with other people. We can't take anything with us when we leave this planet except our relationships. I think that should be a guiding principle in all our life choices. But, being a Lutheran as well as college professor, I know we all make mistakes. If our mistakes, or trying to prevent all mistakes, becomes our life focus, then we risk living our lives for ourselves and not in relationships with others. Anna Bolz Weber, a Luther minister with an extraordinary life story, gave a lecture at Luther College on Friday March 31st where she said many of these things that I believe so strongly. She teaches that God has freed us from the worry of being in charge. We are not perfect. But freedom from worry about ourselves means we can live as God intended, in relationship with others.

I would add that along the way we can still have a little fun taking things apart to see how they work!

Finding Success at Luther College

We all want to be successful in life. But it is an elusive goal! I feel I have been successful while teaching at Luther, but it is still a daily struggle to know if I am doing the best I can. As a parent I want my children to be successful. As an advisor and teacher I want my students to be successful as well. But what does it mean to be successful as a student at Luther? How can students, and alums, know if they are finding success in their lives?

As a part of my job I have the opportunity to have conversations with students about their goals once they graduate. At one point a student was very honest with me when he said that when he leaves Luther he wants to make a lot of money. I appreciate his honesty and when it comes right down to it, don’t we all want to make enough money to be comfortable? Our society sees that as a sign of success. Most of us want to travel and have leisure time. We want our children to have at least as good a life as ours and usually we want something better for our kids. Traveling, leisure time, having a better life for our kids; in the end they all require money. So is money a good measure of success?

Of course, success isn’t all about making money. Recently, I have had conversations with two top executives from two large corporations. For both of them, their jobs demand that much of their lives revolve around the companies for which they work. They live in hotel rooms sometimes as much as five days a week visiting sites where their company has a presence. In both cases, these executives climbed the corporate ladder working hard to be successful. But, at what cost to themselves and their families? Both of them have shared with me that they don’t feel that successful. It is not the glamorous life that some would see from the outside looking in.

So, what does success look like? What should we strive for? As a Lutheran pastor’s son I have heard some good sermons on this topic. It is at the center of what many people struggle with no matter which religion they practice or whether they practice any religion at all. What is the meaning of success in life?

Both these executives have shared with me that they are missing deep personal connections with other people on a daily basis. Both of them have people in their lives that they love and that love them. But it is that daily connection with people that love them that is lacking. We all need this in our lives: personal connection with others.

To be clear I am not preaching against making money. Money is important in our society. We need it for security from hunger, shelter from the elements, and for some leisure time and travel as well. But it should not be our only measure of success. And when money is put to work to help others, that can open doors to even more personal relationships. So money can be a really good thing when it is used effectively.

As a teacher and advisor I enjoy the relationships I have with my students. Getting to know these young people keeps me young as well. As a Computer Science teacher at Luther I get excited about making introductions between my present and past students not just because of the networking it provides but because it is another connection in their lives as well as mine.

My wish for you and for me is that we find success in our personal lives and careers by building those deep personal connections to other people. In the end, these relationships are the only thing we take with us! Love your neighbor as yourself (Mark 12:31)! This is not a trivial mandate, but it is good advice. Success comes in many forms but in the end I am convinced that all success boils down to building personal relationships with others. This should be our test of success and something we keep in mind as we make decisions about our futures!

-- Soli Deo Gloria,

Kent D. Lee

This was also published on the Ideas and Creations Blog at Luther College.

Learning To Speak Python

Recently a post on Slashdot.org drew attention to an article on the best paid programming language skills. Python programmers are often commanding six figure salaries. We've been teaching Python as our introductory language for many years at Luther. Not only is it a viable language in the REAL WORLD, it is also a decent language to teach introductory programming.

http://developers.slashdot.org/story/14/12/03/177214/which-programming-language-pays-the-best-probably-python

It's interesting that all of the languages mentioned in this post are taught in our Computer Science curriculum at Luther College. And, our graduates are getting paid these good salaries too! It's good to be a CS major! Not only is it a creative and interesting discipline, you are paid well, too.

Coding Bootcamp

In a recent interview on CNN Money, college graduates are interviewed after attending a 19 week training course to become computer programmers. The course was called Dev Bootcamp and the students paid $12,000 to attend this program. They are called coders by the interviewer, but are they really prepared?

http://money.cnn.com/video/pf/2014/11/14/ivory-tower-coding-bootcamp.cnnmoney/index.html

One student said that she didn't take Computer Science in college because she would not have learned web programming. That's not true at Luther College! We have been teaching web programming for close to 10 years. Web programming really consists of two pieces, Database programming and Internet programming and we teach both at Luther. In addition, we teach a lot of other topics that help support these important skills and we prepare students for jobs in all areas of Computer Science from graduate school to jobs at Google, Microsoft, IBM, Lockheed-Martin, Medtronic, Fastenal, Federated Insurance, Epic Systems, Rockwell-Collins, and many, many other companies. Our graduates are working coast to coast and around the world.

There is no doubt that you can learn some programming skills in 19 weeks and maybe even find a job using those skills. A student in the program claims the graduates of their program are junior web developers. A Luther Computer Science graduate has been exposed to the bigger picture and understands how quickly the field changes. Luther CS graduates have the skills to teach themselves and adapt with the field. It's not clear that those with 19 weeks of experience will be able to adapt in the same way.

I think everyone should learn to program a computer, and I congratulate those in the interview that are taking that initiative. But, wouldn't it be great to attend a college where you can learn the skills you need to stay relevant in a changing tech world and not have to pay an additional $12,000 and spend another 6 months learning to program after college? When you factor in the lost salary that on average is costing those students $35,000 (based on an average computer programmer starting salary of $63,000 per year plus the cost of their program). Come to Luther! Graduate in 4 years. Study Computer Science and make a wise investment in your future!

Teach a Person to Fish

I was reminded this morning of the saying that goes something like this: Give a man a fish, feed him for a day. Teach a man to fish and feed him for a lifetime. The saying embodies something I firmly believe for teaching Computer Science. I'll rewrite the saying for CS as Teach a person to program, create a programmer for today. Teach a person to understand how their program works, create a programmer for a lifetime. Every day there are new technologies being created in the world of programming. Buzz words like web servers, web services, cloud services, databases, and big data abound because at some point they were the latest and greatest. How can students hope to understand all these technologies with just four years of college? They can't.

Being a computer programmer requires a lifetime of learning. It is my job as a Computer Science professor to provide tools students can use to continue to learn these new technologies as they need them. The required tools are the learning to fish in the saying above. Teaching students how things work is what teaching Computer Science is all about. In my courses students not only learn how to program, they learn how their programs work. Underlying all computer programs is a relatively stable computational model. If you understand that model you have a reference point for learning all these new technologies. Humans learn by being able to draw analogies to other things. We constantly make associations in our brains: This is like that other thing I learned yesterday, so now I understand this too! With an understanding of the computational model used by programming languages, students have the tools they need to say, Oh, this is like that other thing I learned yesterday! And, so starts a lifetime of learning...

Luther College Attends ACM Programming Contest

../galleries/Contest2014.jpg

Luther College Computer Science majors Jacob Albee, Isaac Davis, Isaac Dontje-Lindell, Isabelle Krogh, Nathan Lee, Robbie Nesmith, Kirby Olson, Cadence Sawyer, and Ellen Widerski attended the ACM North Central North American Regional Programming Contest sponsored by IBM where they formed three groups of three programmers each. They were competing with approximately 220 other teams of three in a contest held at multiple sites across the upper midwest. The Luther College teams competed at Carleton College where teams from Carleton, Macalester, Gustavus, St. Johns, and St. Olaf were also competing. Two teams from this site placed in the top 10 in the region including one team from Carleton, which solved eight of the nine problems and finished fourth overall, and one from Macalester that solved seven of the nine problems and finished eighth overall.

The top teams from the regional contest attend the ACM Programming Contest World Finals which will be held in Morocco, May 16-21 2015. Luther College last had a team earn a top spot at the regionals and make it to the World Finals in 2001 when Stefan Atev, Mark Pasch, and Jessica Oftelie attended the contest which was held in Vancouver, British Columbia that year.

Python Programming Fundamentals 2nd Edition

I am pleased to announce the second edition of my text Python Programming Fundamentals. This text is an introductory Computer Science text that has been classroom tested and used successfully in classrooms around the world. The text also has accompanying video lectures available on YouTube. Just go to https://www.youtube.com/user/CSProfessor to view the video lectures that accompany this text. In this update I present a new project in the first chapter and do a little more Object-Oriented programming towards the end of the text. A support website for the text is located at http://cs.luther.edu/~leekent/CS1.

This text is published by Springer Publishing and will be available in early 2015.

Data Structures and Algorithms with Python

Steve Hubbard and I are proud to announce our forthcoming text, Data Structures and Algorithms with Python. This text is both an introductory data structures and algorithms book and a text for an advanced data structures course. The text covers the introductory topics of sorting, searching, stacks, queues, linked lists, sets, maps, and a little graph theory. It also covers advanced topics like heaps, AVL trees, Splay Trees, B-Trees, and a heuristic search algorithms.

The text already has an accompanying website at http://cs.luther.edu/~leekent/CS2Plus where many teaching materials can be found. This text covers topics and projects developed during Professor Hubbard's many years teaching advanced data structures. The text picks up where the successful introductory text, Python Programming Fundamental, left off using turtle graphics to plot experimental results and explore issues of computational complexity. The material covered in these two texts readies the student for the more advanced courses covered in a Computer Science major or minor.

The text is being published by Springer Publishing and will be available in early 2015.

Presenting at SIGCSE 2015

I will be presenting the paper, A Framework for Teaching Programming Languages, at SIGCSE 2015 (i.e. the Special Interest Group on Computer Science Education of the Association for Computing Machinery - you can see why it is abbreviated SIGCSE). The paper covers a new framework for disassembling Python programs, a virtual machine called CoCo, a compiler for Standard ML (written in Standard ML) that targets the CoCo virtual machine, and a type inference system for Standard ML (written in Prolog). The paper covers the content of a one semester course on Programming Languages using this framework. I am excited to share this with others in Computer Science. The semester content is covered in much more detail and written for students in my recently announced text, Foundations of Programming Languages.

A New Programming Languages Text

I am excited to announce that I am publishing a new programming languages text called Foundations of Programming Languages with Springer Publishing. This text uses a framework I developed for teaching programming languages. The framework consists of a disassembler, a virtual machine, and a compiler for a significant subset of Standard ML.

The Python disassembler disassembles Python code into CoCo assembly language. CoCo is a virtual machine that I wrote in C++ which is based on the Python Virtual Machine. The C++ code for CoCo is freely available at http://github.com/kentdlee/CoCo. Through the C++ implementation students see a significant project implemented in C++ along with the implementation of a virtual machine. By using the Python disassembler students can write Python programs and disassemble them into CoCo programs to learn the CoCo assembly language and how a high-level language like Python is mapped into a low-level language like CoCo. The new text covers the syntax, semantics, and implementation of the CoCo virtual machine and its assembly language.

The text goes on to use CoCo as the target language for a compiler for Standard ML. The compiler project is called MLComp and is available at http://github.com/kentdlee/MLComp. The compiler is written in Standard ML showing students a significant project written in Standard ML. The MLComp compiler translates Standard ML programs into CoCo programs. Chapter 5 of the text introduces students to Standard ML and functional programming while in chapter 6 they learn how to extend the MLComp compiler by compiling a series of test cases. The subset of Standard ML compiled by the MLComp compiler is called the Small language.

The last two chapters of the text introduce students to Prolog programming and use Prolog to implement a type inference system to typecheck Small programs. Logic, inference, and unification are all important concepts in Computer Science and exploring the proven sound and correct type inference system of Standard ML is the perfect reason to learn these concepts.

The text will be available in early 2015. The CoCo and MLComp projects are available now on GitHub. If you are interested in more information, don't hesitate to contact me.

Share