What’s Going On in My Waifu’s Head: An Insight Into Problem Solving

Frosted bubble here. Today, I’m just going to be babbling on and on about random thoughts I have had about problem solving and thinking in general.

Have you ever thought about how we humans learn, actually perform, and improve on problem solving? As a competitive programmer, I have done lots and lots of questions, most mathematical in nature. Sometimes, I like to step back and reflect on how I tend to think and how I eventually arrived at a solution. 

In university, I have a professor that describes it as such: in the beginning, we have an arsenal of tools. Solving a problem is essentially randomly choosing some tool, working on the problem a bit, and seeing if the problem reduces into something simpler that can be worked further. Thus, we can imagine that everyone has some sort of probability distribution on this set of tools, and “getting better” at solving problems is just building an intuition of what tools to use when, and optimizing this random distribution.

I think that my professor gives a good summary of how it feels when trying to tackle a problem. In competitive programming, there is a set of algorithms and data structures that seem to be what most problems or solutions are based off of. These are our tools. A lot of the times when I’m just starting a problem, I realize I do tend to cycle through a few of these tools that seem likely and try to approach the problem using each of these tools. 

Of course, it’s still a simplification, and this isn’t how it always is. A lot of the time, it feels like I’m repeatedly simulating different scenarios until I’m able to find some clever pattern/mathematical observation that simplifies the problem greatly. This process of finding patterns itself also feels very random, though there are also a few sets of “tools” that can sometimes help. Some examples are visualization, transforming the problem/viewing the problem from a different perspective, limiting the scope of the problem to a simpler version and starting from there. These “tools” are probably universal and can be applied to any sort of problem solving.

There are also skills that I would argue all thinking is based off of. These skills are so fundamental it is unclear whether they can be improved. The largest one is your working memory, aka short-term memory. I would say it’s similar to computer RAMs. When I’m working on a coding problem and I’m deep down some line of thought, I realize that very often I forget why or how I’m at where I’m at. For example, let’s say I’m analyzing property A. I spend some time working on A and realize that A implies that B is true; I spend more time on B and realize that B implies that C is true. Now, putting in a lot of time into C, I begin to doubt why C is true and question how I got to B, but I have already forgotten how I got to B, and I now begin to doubt the truthfulness of B. What happens then is that I repeat this line of reasoning a few times, until either I get stuck at C and give up, or I have repeated enough times that I find that C implies D is true. I would say that this is an example of working memory, or rather the lack of working memory.

Another skill I think is essential to problem solving is creativity. I’m not quite sure how to relate creativity with this “random distribution” model I mentioned before, because creativity itself seems to be random. Creativity is often described as “the ability to think outside the box,” and it really does feel that way. The times I’ve felt the most creative are when faced with a problem and stuck with limited “paths of thinking”, I spontaneously arrive at a new line of thought, almost unrelated to what I was thinking about before. Perhaps then one way to describe it would be “the ability to consciously come up with random thoughts?” Coming up with random thoughts is surprisingly hard for people, since most of our thoughts stem from what we were thinking before/our memories. People say that creativity is trained, and I’d also like to believe it as well; maybe you can’t get better at forcing your brain to come up with random thoughts, but you definitely can practice getting into a state where it’s easier for your brain to do so (ex: being relaxed).

Now, from all of this, one thing I like to think about is what this tells us about unsolved problems from centuries ago? For example, P vs. NP is an unsolved problem from ages ago, roughly asking whether a problem can be “quickly” solved with a computer if a solution can be “quickly” checked with one. Is the reason that we haven’t solved these problems that its solution requires a very, very obscure “tool”, or is it because its solution requires very, very deep analysis that makes it difficult for humans to remember and perform, or is it because its solution simply is just hard to find using the way that humans like to think? I believe that our math, our thinking is heavily inspired from nature, from what exists around us. For example, our number system is base 10, probably because we have 10 fingers; the fundamentals of our math system is based on addition, subtraction, multiplication, division; a lot of our algorithms are inspired by “greedy” thinking (“what happens if I just choose the most obvious choice without worrying about the future?”), and this is the case for a lot of graph algorithms such as shortest path, flow. 

The more developed and complex the subjects we learn from are, the less “intuitive” and the less “human” they are. When I was young, I remember being bewildered by what an “average” was. I eventually gave up trying to “understand” it, and just memorized the definition: “add all of the numbers and divide the sum by the number of numbers.” Now, it seems almost like second nature, but if I truly ask myself if I know what an “average” is, if a five-year-old asked me that question, I wouldn’t know how to answer. In math, and probably most things, each result is built off of previous results, with the first result being direct observations we make of the world. These first observations are made out of the necessity to survive, and our brains probably evolved to make understanding these observations their largest priority. Then sometimes when I’m daydreaming, I like to ask myself, how different would our thinking be if we weren’t humans, if we weren’t restricted to this physical world? How different would our mathematics be, what problems would we solve/not solve? How would a God learn math?

I actually haven’t thought very deeply about a lot of the thoughts and questions I have written here. I hope they are interesting to think about though, even if I can’t provide much insight into them.

I might eat frosted flakes tomorrow,
Frosted Bubble

Leave a Reply