Notes from reading Up and Down the Ladder of Abstraction ↗ by Bret Victor.
real-time makes sense for things that need to be watched in real-time (like an animation)
the same way we scrub through time we should be able to scrub through variables
then, we can abstract over time - draw a path of what something will look like, and change the variables to see the path change, without having to scrub through it
then, we can then abstract over time and a parameter - drawing all possible behaviours of the algorithm
the purpose of abstraction is to bring out high-level patterns
We stepped up a level of abstraction to see a high-level pattern, and then stepped down to discover the explanation for that pattern. I believe that this dance is where the deepest insights are born - not at any one level of abstraction, but in the transitions between them. This is why it is crucial that our representations provide both a step up and a step back down.
when abstracting, it's ok to omit some details to gain better understanding of the system
interaction is important part of abstraction - being able to interact with the visualization (and see other visualizations change) helps us build mental model of the solution space (Solving Things Visually)
how this relates to programming:
function f() {
const t = 100;
const r = 2;
const [x, y] = calculate(t, r);
return [x, y];
}
function f(t) {
const r = 2;
const [x, y] = calculate(t, r);
return [x, y];
}
function f(t, r) {
const [x, y] = calculate(t, r);
return [x, y];
}
r
is currying:
const f_of_2 = t => f(t, 2);
401 words last tended to on 2021-06-10 — let me know what you think