Intro to CS: Lecture 4 - Loops over strings, guess-and-check, and binary

This lecture explains iteration in simple programs like guess-and-check, binaries, and fractions in Python. Loops can iterate over any sequence of values including a range for numbers or a string. Guess-and-check provides a simple algorithm for solving problems. When the set of potential solutions is enumerable, exhaustive enumeration is guaranteed …



Intro to CS: Lecture 3 - Iteration

Going over while and for loops. This is basic stuff for me. Watching video at 2x speed. Done watching, no new things learned. Onward to lecture 4.



Intro to CS: Lecture 2 - Strings, Input/Output, Branching

This blog post might be really short as I don’t feel like repeating things that I already know. Will keep watching the lecture to see if anything interesting pops up. Watching lectures on 2x speed. Topics: Core Elements of Programs: strings, input/output, f-strings, operators, branching, indentation. I already …



Intro to CS: Lecture 1 - Introduction

Here are my notes and thoughts about this lecture. Topics: Introduction to Python: knowledge, machines, objects, types, variables, bindings, IDEs. Declarative vs. imperative knowledge. The former is statements of fact while the latter is a recipe or “how to”. In this course we will be dealing with mostly imperative knowledge …



Taking a new course - Intro to CS and Programming using Python

Decided to take intro to CS using Python from MIT. Yes, this is easy basic stuff and my ego is nudging me to not proceed because “I already know this stuff”. And I feel like I’m already well-versed in Python, so why am I taking this course? Mostly out …



Systematic Program Design: Week 6b - Mutual Reference

We are presented with a new data structure for arbitrarily wide and arbitrarily deep tree structures. The example given is a file system. This structure reminds me of the Trie data structure implementation in Python, because of the list of nodes data referencing itself. In this course’s terms, it …



Systematic Program Design: Space Invaders Project

Just completed the midterm project which was to implement Space Invaders game! It's pretty easy if you paid attention to all the lessons leading up to here. I started by doing a domain analysis using pen and paper. I also wrote out all the scenarios, such as changing direction when …



Math for CS: Problem Set 1 Reflection

I didn’t find the first proofs to be easy. It required creative mathematical thinking using algebraic rules, some of which I have forgotten. To not waste too much time, I gave it an honest attempt for 16-32 min, then after I was surely stuck, I looked up the solution …



Systematic Program Design: Week 6a - Binary Search Trees

Module overview/summary: Binary Search Trees In this module we will investigate how the structure of data affects performance, especially when it comes to the time required to find an element in a large data store. As part of that we will discover a new self-referential form of data, the …



Math for CS: Quantifiers and Predicate Logic

We start off with quantifiers. There are two of them. “For all” and “there exists”, each with their own notation. For all is an upside down A and there exists is a backwards E. We are also introduced to predicates. a predicate is a statement that contains a variable and …