Things SPARC

I often get asked about what I learned from the SPARC summer camp. This is hard to describe and I never manage to give as a good of an answer as I want, so I want to take the time to write down something concrete now. For context: I attended SPARC in 2013 and 2014 and again as a counselor in 2015, so this post is long overdue (but better late than never).

(For those of you still in high school: applications for 2016 are now open, due March 1, 2016. The program is completely free including room/board and you don’t need rec letters, so there is no reason to not apply.)

The short version is that about 1/3 to 1/2 of the life skills I use on a regular basis are things I picked up from SPARC. (The rest came from some combination of math contests and living in college dorms.) On paper SPARC seems like a math or CS camp, but there is a strong emphasis on practicality in the sense that the instructors specifically want to teach you things that you can apply in life. So in addition to technical classes on Bayes’ theorem and the like, you’ll have classes on much “softer” topics like

  • Posture (literally about having good body posture)
  • Aversion factoring (e.g. understanding why I’m not exercising and fixing it)
  • Expanding comfort zones (with hands-on practice; my year I learned to climb trees)

and so on. This makes it hard to compare to other math camps like MOP (though if you insist on drawing a comparison, I think most MOP+SPARC students agree they learned more from SPARC).

Some more testimonials:

Now, here is my own list of concrete things which SPARC has taught me, in no particular order:

  • Being significantly more introspective / reflective about life. Example: realizing that some class/activity/etc. are not adding much value to life and dropping them.
  • Being interested in optimizing life in general; I now find it fun to think about how to be more productive and live life well the same way I like to think about hard math problems.
  • Thinking about thinking: things like mental models, cognitive biases, emotions, aversions, System 1 vs System 2,
  • Becoming very aggressive at conserving time. I’m much more willing to trade money for time, and actively asking whether I really need to do something, or if I can just axe it.
  • Using game theory concepts to think about the world. College tuition is expensive because this is the Nash equilibrium. Recognizing real-life situations which are well understood as games, like prisoner’s dilemma, chicken, etc.
  • Applying Bayes’ theorem and expected value to real life. Trying out X activity has constant cost but potentially large payoffs, hence large positive EV.
  • Being able to use probabilities in a meaningful way. Being able to tell the difference between being 90% confident and 70% confident in an event happening.
  • Actively buying O(n) returns for O(1) cost.
  • Being more willing to take less conventional paths, like essentially dropping out of high school to train for the IMO (I describe this in the first FAQ here). Another good example I haven’t done myself (yet) is taking a gap year.
  • Using Workflowy. It’s a big part of why I can think as clearly as I do. In context of SPARC, this is a special case of understanding the idea of working memory, which is also an idea I picked up from camp.
  • Writing a lot more. This is probably actually a consequence of the things above rather than something that I directly learned from SPARC; some combination of understanding working memory well, and being much more reflective.
  • Peer group and culture. This is a bigger one than people realize. In the same way that math contests establish a group of people where it’s cool to think about hard math problems, the SPARC network establishes a group of people with a culture of encouraging people to think about rationality. It’s very hard to be good at reflection in an isolated environment! SPARC lets you see how other people go about thinking about how to live life well and gives you other people to bounce ideas off of.

I’m sure there’s other things, but it’s hard for me to notice since it’s been so long since I had to live life pre-SPARC. And there’s some things that other people learned from SPARC that never stuck with me (lots of the social skills, for example). Much like your first time attending MOP, there will be more things to learn than you’ll actually be able to absorb. So the list above is only the things that I myself learned, and in fact I think the set of things you acquire from SPARC more or less molds to whichever particular things matter to you most.

Conversations

I’ve recently come to believe that “deep conversations” are overrated. Here is why.

Memory

Human short term memory is pretty crummy. Here is an illustration from linguistics:

A man that a woman that a child that a bird that I heard saw knows loves

This is a well-formed English phrase. And yet parsing it is difficult, because you need a stack of size four. Four is a pretty big number.

And that’s after I’ve written the sentence down for you, so your eyes could scan it two or three times to try and parse it. Imagine if I instead said this sentence aloud.

Other examples include any object with some moderately complex structure:

Let ABC be a triangle and let AD, BE, CF be altitudes concurrent at the orthocenter H.

This is not a very complicated diagram, but it’s also very difficult to capture in your head unless you’ve seen it before — and again, that’s after I’ve written it down for your viewing pleasure.

Now imagine what you’re talking about isn’t just six lines and seven points, but “what do you think the point of college is?”, or “should a high school diploma be required to obtain a driver’s license?”, or “what is algebraic geometry about?” (all examples from my life, mind you). The answer to these questions is far more complex than the trivial examples I’ve given above. To try and talk about these things merely by voice seems fruitless.

It’s worth pointing out that you can get away with things that have a lot of breadth as long they do not have depth — loosely, as long as there are not too many dependencies. To give an example, the linguistics example is tricky because all the subjects and verbs depend on each other. The geometry diagram is tricky because the points are all tied together in a certain way. But I could read the first chapter of And Then I Thought I Was A Fish out loud, or tell you the story of the cute girl I met three summers ago, because the parts don’t depend (as much) on one another: at any point in a story you can remember the last couple sentences and still enjoy the story. But if I try to read you the first chapter of The Rising Sea: Foundations of Algebraic Geometry, it would make a good bedtime story only because you’d probably fall asleep.

It just strikes me as bizarre that people talk about “deep” issues without writing a single thing down. I think if you’re having lunch with a friend and discussing something like this, you ought to at least have a piece of paper out on the table where you can both jot down the main ideas of what’s been said. It doesn’t need to have every word because then you just get bloat, but still, at least get the key insights somewhere visible. (That’s what presentation slides and blackboards are for, right?)

Computation

The other strange thing is that in conversations, you have to process and respond in real-time. You can only spend as long thinking about a sentence as it takes for the next one to be said.

This is fine if I ask you a question such as “what is your birthday?”, because lookup queries are fast. It’s fine if I ask you “what did you think of X book you read?”, again because it is just a lookup query. Note that this is true even if you spent a long time reading and thinking about the book, because the computation was already done. It’s even fine if I ask “what is two plus five?” because it takes not very long to add.

But if I ask “what do you think about the war on drugs?” and you haven’t been thinking much about it, then the best answer you can give is “I don’t know”; because you can’t do a lookup query for an answer you haven’t computed yet.

Put another way, suppose someone asks me some complex question like “how do I get better at math contests?”, and I respond “do a lot of problems that are right above your ability”. One of two possible things just happened:

  1. I had already thought about this question, and this is a pre-computed answer, or
  2. I came up with this in the half second between the end of your question and the start of my response. (Though you can increase this time by pre-pending “uh”, “like”, “I think”.)

In other words, the fast nature of conversations prevents anything other than cache lookups and first impressions (or I suppose possibly a combination of both). And if the issue you’re talking about is sufficiently complex, first impressions are likely not so insightful. So if I sound really smart in a conversation, the only reason is that you’re asking questions I already pre-computed good answers for.

In other words, the best you can do from a typical conversation is learn what people’s existing ideas are. There isn’t a tractable way to generate new ideas from feedback, just because the time-scale involved is too small. Eliezer Yudkowsky makes a similar point in a Less Wrong Post:

If you want to sound deep, you can never say anything that is more than a single step of inferential distance away from your listener’s current mental state. That’s just the way it is.

Hypothesis

I will now point out that both issues I mentioned have easy partial fixes. If I’m correct, then deep conversations can be substantially enhanced if we use paper or blackboard or anything else, and agree it is socially acceptable to take a minute to respond. Neither of these actions will completely alleviate their respective problems, but trust me when I say having 60 seconds to think is a world of difference compared to 2.

Both of these initially struck me as weird conclusions, but they do seem to make sense on closer inspection. In fact, I have actually seen both done in practice (albeit not simultaneously). So this means I have a way to test what I’ve written in this post now…

Diversity and Neg EMH

Those of you who know me personally will know how much I don’t like the word “diversity”, so for once let me give an argument in favor of it.

Efficient Market Hypothesis

One of the biggest take-aways I got from freshman year was something I like to call “neg EMH”, short for “negation of the Efficient Market Hypothesis”. This is a concept from economics which roughly says that the market self-regulates due to competition. For our purposes, we can of it more generally as saying

EMH: The world is big, and if you think you see something that everyone else misses you are probably wrong. If you are right, it doesn’t hurt to do a bit of due diligence anyway.

Its negation, then, would go something like

Neg EMH: The world isn’t that big; if you care, are thoughtful and intelligent, and have relevant expertise and skills, you shouldn’t be surprised to see something that no one else does, or do something that no one else can.

(These quotes are from a class at SPARC 2014.)

I think the biggest change I had freshman year was moving from the first point of view to the second point of view and even past it. It’s not merely possible that most people in the world are mistaken, it’s frequently the case. In fact, it’s frequently the case that most of the population is obviously mistaken. The first instance I saw of this was realizing how high school math education was (is) totally broken. Indeed there’s quite an elephant in the room:

You can’t actually be serious. Do people really think that knowing the Pythagorean Theorem will help in your daily life? I sure don’t, and I’m an aspiring mathematician . . . . It’s hilarious when you think about it. We’ve convinced millions of kids all over the country that they’re learning math because it’s useful in their lives, and they grudgingly believe it.

And ironically, the quote above is from an earlier blog post when I described how high school English was also broken. In both cases, people weren’t just wrong about something obscure, they were blatantly wrong about something which ought to have been patently obvious.

Icebergs

I realized that math was broken early in high school, and that writing was broken during about senior year, but at the time I dismissed it as just saying “high school is broken” and thought nothing more of it. It didn’t occur to me to think beyond that box.

Then I went to college and wasted a few hundred hours in one of the worst experiences of my life. It begin to dawn on me that perhaps there were more things that were broken than I thought. So I started looking harder, and I began to notice more and more inefficiencies. To give concrete examples:

  • In some (many) classes, people go to lectures to listen to a professor copy the notes he/she prepared onto a blackboard, then copy down the things on the blackboard into their notebooks. It’s almost like we never invented copy machines. [a]
  • Math textbooks are still written in a deadly boring, formal tone. To me, that’s just absurd. There are no jokes. There are few concrete examples. There is no “this is the standard example you should refer to”, “this is a surprising proof”, “this is just a routine calculation”. There’s rarely even “the main idea of the proof is…”. Instead, all you get is a sea of definitions, lemmas, theorems and proofs, which is often indecipherable.
    No one talks this way. No one thinks this way. Why are so many textbooks written this way?
  • Most people still use Microsoft Word (instead of Vim/LaTeX) and mouse-oriented operating systems and window managers (instead of tiling window managers, say). These are good examples of not buying O(n) returns at O(1) costs.

There are plenty more examples I have, but many are things I’m not really comfortable saying in public, so I’ll refrain from giving more examples [b].

Minority Rule

Now what does this have to do with diversity? Well, you might notice that most of the examples I gave had to do with math and college (and this becomes more true if you look at my full list). In fact, if you asked me what the two things I have the strongest feelings about are, I would say (i) math is usually taught poorly, especially at the lower levels, and (ii) college is an egregious waste of money [c].

What’s with that? Well, these happen to be the two things I think about the most.

This is a reflection of the totally obvious fact that if you spend lots of time thinking about something, you get to see things that most people don’t see [d]. I spend most of my time learning math, so I get to see when things are obviously broken [e]. I’d imagine someone who spends lot of time thinking about effective altruism (say) can probably see tons of inefficiencies there. And I had to spend lots of time thinking about the value of college because I’m applying for transfer. That’s why my views on the value of college are so strong.

This is the main value of talking to people with different specialties. It’s not merely that they see things differently; that’s tautologically true. The sinker is that smart people in different fields can often see that large portions of the population are blatantly wrong. It’s the word “blatantly” that’s important! I make fun of college all the time. I wonder who’s making fun of me.

A corollary: if most people believe X, but a smart “specialist” believes not X, the specialist is likely to be right, at least surprisingly often. (The “smart” condition cannot be dropped.) Put another way: an informed minority, perhaps even a single informed individual, is substantially better than an uninformed majority. That’s the power of neg EMH. So if I were looking for advice on picking colleges again, I’d first go find the kid who transferred out . . .

Go Do Good Things

Another corollary is that it’s easier to change the world than one might expect.

When I was younger, I used to think that “changing the world” was this glamorous thing that was near impossible, but that people attempted anyways for egotistic reasons; I explained to myself that stories of people succeeding were probably just survivor bias.

I still believe the survivor bias part, but I no longer think that most attempts are made by people trying to stroke their egos, but rather people who notice blatant market failures and feel compelled to act. In such a situation, it seems almost stupid not to take a shot. It’s not so much a feeling of “I can be the one to change the world” but rather “why on Earth has no one done this yet?”. That’s what I say all the time when I explain to people how I got the idea behind my geometry book, or any of my olympiad handouts for that matter. It is not Pride that changes the world, but Wrath.

Footnotes

[a] Of course, not all classes are like this, but many of them are, and I actively avoid classes which do this. As a rule of thumb, it’s easier to be personal in smaller classes, so taking higher-numbered classes over intro classes seems to be a good idea in general.

[b] Trust me, I would love to.

[c] Oops, that’s one of the things I was supposed to not say in public, although not one of the big ones. I’ll comment that I try very hard to only take classes that are worth my while. The fact that I actually learned math in high school is the only reason this is possible.

[d] Ironically, this sentence is an argument against individual diversity as follows: if you know a little bit about lots of things, then you don’t get the big “aha” moments in any of them.

[e] Not the math itself, of course, since in math we have proofs. (I imagine in other fields, you might notice things that are clearly wrong.) Though actually I’m told once you’ve delved enough into math research, you’ll can realize things that no one thought of before even though they should have. For example, Grothendieck on schemes…

Email, JetPack, and Wintermelon

So I guess I can resume blogging now, seeing that I’m done with college applications (at last!). I’m not sure what I plan to blog about in general, but I figured I might as well put this domain name to good use :) I also realized that writing things out helped me clarify my thinking a lot (actually Qiaochu Yuan recommended this for math in particular), so I’ll be trying to do that more often this 2014 = 2 * 19 * 53 and onwards.

Onto the actual content, anyways. In this post I’ll talk about the inspiration and development for one of my afternoon projects, which I’ve named wintermelon for no good reason.

A while back Jacob Steinhardt recommended to the SPARC alumni list that we check our email at most twice a day. I was able to follow this suggestion for a day, and really was impressed by the feeling — I realized that I had started to use email as a distraction, something to prevent my brain from realizing it wasn’t do anything. The same went for the Art of Problem Solving forums (which I frequently visit) as well as Facebook, so I also tried limiting the number of times I checked each of those each day. Unfortunately, old habits do not die easily, and I found myself automatically visiting those sites when I wasn’t doing anything.

A couple days ago while I was reviewing my goals and realizing that I wasn’t following this one, I remembered the title text of XKCD 862.
After years of trying various methods, I broke this habit by pitting my impatience against my laziness. I decoupled the action and the neurological reward by setting up a simple 30-second delay I had to wait through, in which I couldn't do anything else, before any new page or chat client would load (and only allowed one to run at once). The urge to check all those sites magically vanished--and my 'productive' computer use was unaffected.

After years of trying various methods, I broke this habit by pitting my impatience against my laziness. I decoupled the action and the neurological reward by setting up a simple 30-second delay I had to wait through, in which I couldn’t do anything else, before any new page or chat client would load (and only allowed one to run at once). The urge to check all those sites magically vanished–and my ‘productive’ computer use was unaffected.

Sounded like fun! The XKCD version seemed a little extreme, but I could definitely do with a script that would make me wait 50 seconds before reading Facebook. I estimated it would take me about two hours to read/learn the API and write the code to put this together; it turns out my estimate was roughly correct.

I’m a Firefox user, so it made sense for me to try and put this together as a Firefox extension. A quick Google search led me to Jetpack, which offered to let me build an FF extension quickly using just JS. They had very nice tutorials, too.

Drilling down, the things I needed to make this thing fly were:

  1. Something to trigger every time a webpage was launched. This was conveniently covered under “Listen for page load”.
  2. Something to actually lock the webpage. This was easy, I just put body.style.visibility = "hidden"; in JS.
  3. Timers for a delay. This was handled by the JS window.setTimeout().
  4. Something to store the websites and their associated delays. I used regular expressions to specify the domain. This I did kind of painlessly through the Jetpack simple-prefs, but it was kind of an ugly hack in that I manually defined six settings for up to six websites. Maybe sometime when I’m bored I will take the time to make this work for arbitrarily many websites.
  5. A way for the individual lockdown scripts to communicate with the main script and vice-versa. This took me a while to figure out, but it is essentially a bunch of emit/on hooks provided in Jetpack. I would inject a script lockdown.js into the page and the send it a signal with the amount of time to lock the page.

It was actually very straightforward in retrospect, and took only a couple files of actual code. The project (which is very small) is posted on my GitHub. My estimate was about right; it took me approximately 2.5 hours from start to finish, although I admit that I was also chatting on Google Talk in the meantime. Actually I’m embarrassed it took as long as that.

The core of the program really is just two files. Here is lib/main.js, which is run from the start.

var widgets = require("sdk/widget");
var tabs = require("sdk/tabs");
var self = require("sdk/self");
var prefs = require("sdk/simple-prefs").prefs

// TODO make these not suck
var regex_strings = new Array();
regex_strings[0] = prefs.regex1;
regex_strings[1] = prefs.regex2;
regex_strings[2] = prefs.regex3;
regex_strings[3] = prefs.regex4;
regex_strings[4] = prefs.regex5;
regex_strings[5] = prefs.regex6;

var lock_times = new Array();
lock_times[0] = prefs.time1;
lock_times[1] = prefs.time2;
lock_times[2] = prefs.time3;
lock_times[3] = prefs.time4;
lock_times[4] = prefs.time5;
lock_times[5] = prefs.time6;

// Create regular expressions
var N = regex_strings.length;
var regexes = new Array();
for (var i=0; i<regex_strings.length; i++) {
  regexes[i] = new RegExp(regex_strings[i]);
}
  
var prev_hit = -1; 
var lockdown = false; // Are we currently in a lockdown?

function lock(time) {
  worker = tabs.activeTab.attach({
    contentScriptFile: self.data.url("lockout.js")
    });
  worker.port.emit("lock", time); // tell the worker to lock
  worker.port.on("unlock", unlock);
  lockdown = true; // prevent side loading
}

function gateway(tab) {
  url = tab.url;
  if (lockdown) {
    // Currently under a lockdown
    // Do not allow any other tabs to load
    lock(lock_times[prev_hit]);
    return;
  }
  for (var i=0; i<N; i++) {
    var regex = regexes[i];
    if (regex.test(url) && regex_strings[i] != "") {
      if (prev_hit != i) {
        // Test positive, we are going to block
        lock(lock_times[i]);
        prev_hit = i; // Remember prev hit
        return;
      }
	  else {
        prev_hit = i; // Still remember prev hit
		return;
	  }
    }
  }
  prev_hit = -1; // Release
}

function unlock() {
  lockdown = false;
}

tabs.on("ready", gateway);

and here is the data/lockout.js that is called by the lock function:

function lock(time) {
	document.getElementsByTagName("body")[0].style.visibility = "hidden";
	if (time >= 0) {
		window.alert("Locking for " + time + " seconds.");
		window.setTimeout(unlock, time * 1000);
	}
	else {
		window.alert("Locking indefinitely.");
	}
}

function unlock() {
	window.alert("Done");
	document.getElementsByTagName("body")[0].style.visibility = "visible";
	self.port.emit("unlock");
}

self.port.on("lock", lock);

More pragmatically, I’ve been using it for only a couple days, but it seems to be working! Blank pages are not very good distractions. We’ll see if this holds up.