CS 330 Lecture 13 – Vtables and Graphing Calculator
Dear students, We saw last time that for subtype polymorphism to work in languages like Java and C++, we need some for way for each object to carry around some information to help us figure out what method to call at runtime. What exactly is that information and how does the runtime decision—the dynamic dispatch—get […]
Pixelated Sphere
I don’t know exactly what magic is made of, but I’m pretty sure it’s spheres. No matter where you stand on a sphere’s surface, you see change. Yet the same change happens everywhere. No point is better than other—until you shine a light on it. But the sphere won’t let the light play favorites. It […]
Pixelated Crate
My 8- and 6-year-old sons and I have been playing EvoLand 2. The game cutely blends action RPGs with platformers with shmups with infinite runners with tactical RPGs with fighting games with menu-based RPGs. Somehow they even squeezed in Snake, Pong, and Pac-Man. Apart from the varied gameplay, EvoLand 2 has inspired us to make […]
CS 318 Lab 8 – Box Model
Dear students, Let’s stop a moment to reflect upon what we have done so far this semester: We’ve organized information in a hierarchy and represented it in plain old text. We’ve seen how to make our text “hyper” through the use of images and links. We’ve added style to established elements of this hierarchy. We’ve […]
CS 330 Lecture 12 – Subtype Polymorphism
Dear students, We introduced four type of polymorphism last time and saw examples of the first two—coercion and ad hoc polymorphism—through the lens of C++. On to a third form: Subtype polymorphism is when a piece of code is targeted to handle an umbrella type, a supertype, but somehow it calls the overridden methods in […]
CS 330 Lecture 11 – Polymorphism: Coercion and Ad Hoc
Dear students, All my favorite talks try to classify some phenomenon in a 2×2 matrix, so let’s do the same. Let’s categorize human endeavors into four buckets based on how much effort is involved and what effect they have: Large Effect polymorphism John Henry learning Vim Small Effect sleeping voting teaching Little Effort Lots of […]
CS 330 Lecture 10 – Type Systems
Dear students, Last time, we introduced types as one of the more prominent distinguishing features of a programming language. We enumerated a bunch of types commonly supported in programming languages. This time, we look at some ways to characterize a language’s type system. To help understand the importance of a language’s type system, imagine if […]
CS 318 Lab 7 – Images
Dear students, I first offer a brief list of recommendations about things I’ve seen you doing that will cause you unnecessary headache: Avoid using spaces in file names. Spaces are not allowed in URLs, so it’s best to just avoid them. They often get translated by our browser into %20, but they will cause issues […]
CS 318 Project – User Study and Sitemap – due on March 1
Your next task in the semester project comes in two pieces: Conduct user studies on several existing websites similar to the one you will design. Compose a sitemap to describe the overall architecture of your site. We describe each of these in turn. Task 1: Comparable Site Test Identify and familiarize yourself with three sites that […]
CS 330 Lecture 9 – Types
Dear students, Today we begin our exploration of programming language concepts, rather than the tools (regex) that we’ll later use for interpreting programming languages. In particular, we start off our discussion with C. I used to talk about assembly first, because no programming language should be evaluated outside the context of history. All that humans […]