Let’s consider a text file: maybe it ends with a newline character, or maybe it doesn’t. Tools like git work more smoothly with files that end in newlines. Command-line tools like cat also produce clearer output when working with files that end in a newline. So, today’s Java programming problem asks you to fix files that don’t end in a newline.
Practice Problem: Is 3 Irrational?
In a first number theory course, there’s typically a proof that the square root of 2 is irrational. The traditional proof uses the properties of divisibility to arrive at a contradiction. We can even swap a 5 into the proof, in place of the 2, to prove the square root of 5 is irrational. But could we do the same with a 9, and “prove” that the square root of 9 is irrational?
Practice Problem: Circular Linked Lists
Linked lists are a topic I frequently discuss with students. So for this month’s blog post, I want to present a linked-list practice problem. We’ll look at a variation on the traditional singly-linked list, called a singly-linked circular list with a tail pointer. How can we insert into this type of list, and how can we search one for a given value?
What’s That Tiny Makefile?
When I’m working with programming students, I usually write a quick Makefile. Only a few lines long, this file allows us to recompile code on the command line just by typing “make”. In this post, we’ll skip over all the details of writing complex Makefiles. Instead, we’ll see how to slap together a rudimentary Makefile in seconds — one that will save us time while we’re working on an assignment.
Mathematical Security of Complex Passwords
One common complexity requirement for passwords is that they contain at least one uppercase letter, one lowercase letter, one number, and one symbol. In this blog post, we’ll explore what effect that complexity requirement has on the mathematical security provided by a password. Specifically, we’ll calculate how many bits of security a password generated with or without this requirement provides.
