Email or username:

Password:

Forgot your password?
David Beazley

This is kind of a weird question, but in your education as a programmer were you ever taught anything that you would describe as a "dimensional shift" in your thinking and if so, what was it?

By "dimensional shift", I mean something deeply profound and different that completely changed the way in which you looked at things.

Not programming, but I'd offer thinking in infinitesimals from math as example.

29 comments
\u1f01a

@dabeaz Functional programming, Haskell style

\u1f01a

@dabeaz
No side effects.
Higher order polymorphism.
Type-level programming.
The only language where I enjoy refactoring (instead of fear it).

b-long

@dabeaz I'll admit that realizing (when learning OOP) an object *held* state was a bit of a surprising and awesome event for me, having only seen Imperative Programming/GOTO at the time. I remember thinking it was a lot of fun to instantiate a light bulb and then turn it ".on()" and ".off()" 🙂

ɗ𐐩ʃƕρʋ

@dabeaz That was when I discovered that variable names in BASIC can have more than one letter, and you can use more than 24 of them in your program.

Greg Wilson

@dabeaz code as data, i.e., introspection and all that it makes possible. blew my tiny little mind.

Martijn Faassen

@dabeaz
Most of the shifts are gradual for me so less profound.

But I do remember a moment long ago where I tried writing automated tests for the first time and found bug after bug in my code. I laughed out loud as it was so simple and yet so empowering.

Even longer ago: recursion. How can a function that calls itself do anything? It seemed like magic at first.

Kartik Agaram

@dabeaz Some shining memories from my life:

* Getting a fancy holographic ruler as a gift at age 5 and holding it tightly in my left hand as I drew freehand squares with my right. Then, a double take.

* Reading a book on OO design at age 18 and writing out the algorithm for the game of life in main() before the double take.

* Staring for a long time at a professor's implementation of list reverse in Lisp, and comparing it with the C version I knew to write.

dorian

@dabeaz @akkartik probably lisp and haskell, one right after the other

Sekenre :python: :c_language:

@dabeaz the ZeroMQ Guide, Redis, building parser combinators out of lambdas, ColorForth. Sqlite. All of these took me to new levels of thinking.

Jared Davis

@sekenre @dabeaz ah the ZeroMQ guide! May Hintjens be blessed RIP

Łukasz Langa

@dabeaz I vividly remember two particular early epiphanies.

The first one was understanding what interfaces are for in Java. At first this was pretty weird to me: strange base classes with no implementations? What good is that? When it clicked for me, a lot of things fell into place.

The other one was pointer arithmetic. The leap from "this number points at an address of a char" to "this number points at a string of chars" was a challenge, and the understanding that came with it felt profound.

Kartik Agaram

@ambv printf vs scanf was particularly challenging. Both can take a pointer to char, but for very different reasons.

@dabeaz

fsan

@dabeaz Learning about Algebraic Data Type specification and having my math friend talk to me about category theory.

Jens W. Klein

@dabeaz magical moments if I discovered free software and suddenly were part of it. This shifted my whole life, discovering whole new social communities, discovering the power of the many working together openly. And so much more.

Ada Wright

@dabeaz i’ve never used Clojure but, after reading a book on it, the beauty of “functional” programming clicked deep, and my Python’s never looked the same again

Alice I Cecile

@dabeaz Functions as first class objects, sum types and traits were the three really big ones for me.

Really expanded my mind by enabling much more elegant, better fitting abstractions.

Chris McDonough ✅

@dabeaz i can't remember it happening to me (although i'm sure it did) but recently I was trying to help a friend's son write an application and he was confused between RAM and storage (in the Harvard architecture senses) and I saw the light bulb go on in real time. But I do remember using ZODB for the first time, which was a dimensional shift in the exact opposite direction, blurring the distinction between storage and RAM.

Jared Davis

@dabeaz I learned infinitesimals “naturally” in 9th grade — it wasn’t until the Weierstrauss limit formalization in college that I found the whole thing strange. Then I don’t think any of either fluxion, classical, or nonstandard analysis made sense to me until the past couple years.

the other dimensional shift for me came in Bill Kennedy’s explications of #golang from a machine-oriented perspective. That was the first time it finally clicked for me: code is human expressions of machine behaviors

bignose

@dabeaz

Several did this for me. They won't be too surprising, as they are paradigm shifts for many people.

To a small degree, object-oriented programming was such a shift.

To a larger degree, functional programming.

Event-based programming.

Generator expressions.

A whole parcel of concepts from statistics.

Promises, futures, and other collaborative asynchronous programming.

Erik Mogensen

@dabeaz It would have to be when my mentor told me about statecharts. It profoundly changed how I view and write software. I think it's a curse on our profession that we as an industry still produce software with this amount of state bugs. How many programs start working after restarting? It's a travesty.

I made statecharts.dev/ as a form of ... antidote.

#statecharts #fsm

Michael Hartle

@dabeaz Uh, there were a number, and I enjoyed these "clicking" moments; my highlights were discovering

* computers and BASIC early at the age of 7,
* how the HDD head parking tool at school worked from disassembly, and slightly adapting it for a teacher
* the idea of rule-driven programming languages, and computing a fixed-point of facts in Datalog, such as how a PNG file is composed from its parts according to data format rules,

Michael Hartle

@dabeaz * the world of functional programming, immutability, applying it to streams, and then reactive, turning pages of source code in (at least for me) eye-openingly simple & concise pivoting / wrangling of data,
* event-driven architectures, CQRS and how processing event streams is "just" folding, partitioning of events, and how this affects the extensibility and horizontal scalability of systems
* and lots more

Matthew Skelton

@dabeaz for me, a major "aha" moment was when I really grokked deployment pipelines as defined in the book Continuous Delivery - the implications for flow, team ownership, and architecture are profound.

Example: speakerdeck.com/matthewskelton

max22-

@dabeaz immediate mode GUIs, it becomes way easier (at least for my brain) to write dynamic and complex user interfaces. and you can understand quite easily how it works under the hood, and write your own library if you want (good tutorial here on how to write your own from scratch: solhsa.com/imgui )

David JONES

@dabeaz regex/DFA equivalence (and the limits of regex); Turing machine/lambda calculus/register machine all being equivalent.

David Beazley

@drj Did any of this change the way that you program or think about problem solving?

Go Up