How to solve quant puzzlesAug 28, 2023
Okay, so this was the puzzle, friend, what's up with my disciples coding Jesus here? If you are new to this channel, welcome. My name is Jesus coder. I'm a
quantitative developer, which means I write server-side and client-side applications for traders at the company I work at now. This video is a highly requested video. It's a video about how to
puzzlesbut more specifically how to
puzzles. jane street now i am going to look at jane street puzzles as a basis for this video but all the tips and tricks that i will give you on how to solve quantitative puzzles based on my own experience will be applicable to all quantitative puzzles, whether it is a puzzle that is obtained in the interview or a riddle that is obtained simply by looking. in online puzzles, all of these tips will be applicable now, why am I in a unique position to speak highly of this in 2020?
I was Jane Street's number one puzzle solver, what does that mean? What the hell is Jane Street? How does this work? Well, Jane Street is a very highly respected company in the quantitative trading space, they are a big company and every month they will publish a puzzle. What are they going to give people that month to solve that puzzle? I assume they will receive thousands, if not tens of thousands, of submissions and the people who answer that puzzle correctly have a chance to get their name on the leaderboard when I say I have solved these puzzles, you can go ahead and check that my name is on on all those leaderboards.
Alright guys, without further ado, let's get into my four to five tips on how to approach quantitative puzzles in specific reference to jane street puzzles the first thing you need to understand is your toolset what is available to you what skills you possess or not very good many people may be watching this video great at linguistics maybe some people are great at math maybe some people are great at programming now one of the biggest misconceptions when it comes to quantitative puzzles is that everyone focuses on the math and you have to be some kind of math genius, guys, I'm I'm not a math genius.
My highest math grade is a sophomore statistics course. I'm not a math whiz and I didn't use math for the vast majority of these puzzles. In fact, many quantitative puzzles focus on things beyond mathematics, such as spatial reasoning. to go ahead and solve puzzles, in fact, one of the hardest puzzles I've ever solved that we'll get to maybe later in this video is a chess-focused puzzle. So you need to understand what's in your toolbox. My personal toolbox. My strong point is. programming I'm not a good mathematician, I'm good with spatial reasoning, so when I think about what I can use to solve puzzles, programming immediately appears in my toolbox.
Now, let's take a look at a Jane Street puzzle I solved. first james street char that puzzle I solved and think about it in programming terms my worked solutions jane street puzzles my working solution then my answers to all the puzzles I've solved I'm going to talk right now about October 2019 puzzle called try try again, so if you look at the try, try again dot cpp this is where I detailed my approach, I detailed the classes that I have, the different methods that I did to speed up the solution, slow down the solution and We will also have at the top right of I display a video showing my algorithm in action as it plays.
Let's go ahead and look for that puzzle in the James Street Puzzle Archive. Please try again if we go to the solution tab like You can see my name is here next to What is this? Another 30 to 50 people who also solve this puzzle. Let's take a look at what the puzzle is to better understand it in the context of understanding your own personal toolset. Okay, so this. it was the puzzle guy, what kind of board did you have here and I'm not going to go into an hour long explanation of what I did so bear with me but first let's read what the puzzle is so we can understand what kind. of tools one can use to solve this place a collection of right triangles on the grid below the triangles should have integer length legs and the legs should be along the length of the grid or grid lines, meaning they cannot stick out from these grid lines, they have to stay on this grid, each triangle must contain exactly one number, that number represents the area of the triangle that contains it, each number must eventually be contained in exactly one triangle , so I can't have more than one triangle containing the same number and I can't.
I don't have two numbers or two or more numbers in a triangle, the whole square, so the whole cell containing the number, one by one, must be inside the triangle, so this number 14, for example, I can't have the edge of a triangle touching this 14, the 14 must be completely inside a triangle, the interiors of the triangles must not overlap, but the boundaries of the triangles can intersect, as seen in this example. As you answer this month's puzzle, submit the product of the odd horizontal lengths of the legs, so here's an example with a smaller grid now when I looked at this puzzle I needed to think about my own personal toolkit is empty my toolset involves programming maybe a little math maybe a little spatial reasoning I could have gone the spatial reasoning route here and started drawing triangles but the sheer number of triangle combinations here is so vast that my ability to reason this spatially it is not strong enough.
Now I'm not going to go into exactly every line of code I wrote for this problem. You can move on. and see it here, I documented it in full, so you can go ahead and take a look at my code here, how I was able to cut the execution time in half, etc., etc., this brings me to the next point I want. What to talk about and that is understanding your personal strengths and weaknesses when it comes to solving a puzzle especially if the puzzle is done in an interview you need to understand what you are good at and what you are not good at and be extremely self aware in In that sense many times we try to tackle a problem on our own when we tackle a problem on our own we run into a stone wall because we don't have the skills necessary to really make progress in solving this puzzle now I'm a person that's clever and I I like to use my resources and take advantage of my resources when it comes to solving puzzles where I reach barriers that I can't cross.
What does that mean? If a puzzle requires a higher degree of spatial reasoning, I could, for example, write down my current approach and ask on an online forum, for example, if someone else is stronger at spatial reasoning with me, can they help me overcome this barrier? ? this is my current approach, this is my current thinking, this is where I'm stuck, this is where I can I think I can improve with the help of someone else and in fact, if you go to the Jane Street website and look at the charts classification, many people submit answers with the group of people they solved that puzzle with as many times you will solve it.
These problems with a group of people are because they will play to each other's strengths. This brings me to the third point I would like to discuss and that is perseverance. Now I can't teach them to persevere. I can't tell you how to persevere. Chances are, perseverance is something you were born with that was solidified when you were 12 years old. In fact, there is a very interesting study that I would like to show you about perseverance: do Asian children accept struggle in learning and American children? give up, so study by a Ucla professor on the differences between how East and West approach the experience of intellectual struggle.
He observed how in Japanese classrooms teachers consciously designed tasks that were slightly beyond the capacity of the students they actively taught and pointed out. that students achieve tasks through work, sorry, through hard work and struggle in the US, the focus is more on intelligence as an acquired skill, so this paraphrases the study, so we did a I studied many years ago with first grade students and we decided to go out. and we gave students an impossible math problem to work on, then we measured how long they worked on it before giving up. The American students worked on it for less than 30 seconds on average and then they basically looked at us and said we hadn't had This is so I've never seen it before and guys, in all the quantitative puzzles I've solved, I've never seen them before, so imagine I give up halfway and eventually solve that puzzle, that would have been shit, but the Japanese. the students worked for the entire hour on the impossible problem and finally we had to stop the session because the hour was up and then we had to inform them and say oh that wasn't a possible problem, that was an impossible problem and they looked at us like What kind of animals are we right?
So there's a big difference between learning through struggle and learning by simply relying on acquired knowledge or acquired skills, and often while you can rely on bits and pieces of acquired skills and quantitative problems, often the biggest driver is acquisition. through fighting and acquiring intelligence through fighting, this brings me to the fourth point guys, the fourth thing I want to talk about in terms of how to solve puzzles based on quantifications and this is spatial reasoning, very well, many times when they give you a riddle. it is given esoteric wording or given with components that involve moving and manipulating objects in the head when it comes to increasing spatial reasoning.
It's very difficult, but not impossible, the way I think I trained spatial reasoning for myself, especially when I was growing up around, you know, 15 16 is I was solving Rubik's cubes and I started with a two-by-two Rubik's cube. and I worked three by three, five by five and at home I even had a 12 by 12 Rubik's cube now for the Once I got to a 12 by 12 Rubik's cube, I already knew in general how to solve Rubik's cubes, certain patterns involved, but try something simple, try a two by two Rubik's cube, don't try the one by one Rubik's cube.
Okay, try the two-by-twos. two Rubik's cubes and try to solve it, try to go ahead and move it and manipulate it because when you try to solve a problem using spatial reasoning you need to think of various paths in advance and what they will look like when you do it. about solving a problem and, in fact, people who play chess and who do it at a high level have a very high level of spatial reasoning because they need to think of multiple scenarios in their head not only in relation to what they will do but in relation to with what the other person will do, let's take a look at a Jane Street puzzle involving spatial reasoning where I can explain to you how I reasoned through this puzzle.
Alright guys, this is the puzzle for June 2020. Ring a ring. Circles of circles. collection of six circles of equal radius friend, I don't understand it, I don't understand it either ring ring ring ring let's say r whose centers are at the six vertices of a regular hexagon with side length 2r, this makes each circle tangent to its two neighbors and we can call the center of the regular hexagon the center of the ring of circles if we are given a circle c what is the maximum proportion of the area of the circle that we can cover with rings of circles entirely contained within c that are all?
They are mutually separate and share the same center, which is fine, when submitting an answer you can submit a solution in closed form or your answer with six decimal places. There are a lot of fragments here, but this involves spatial reasoning because, in particular, you need to draw what the question says so that you understand what the question is. well, this must be a drawing, whether on paper or in your head, that you need to distinguish some people who are mathematicians. Genius kids will submit a closed form. The solution is fine because they have enough experience that it is not part of my toolkit.
I'm going to submit a code based answer and I'll get there by writing code and I'll have to submit it to six decimal places now. You guys can once again take a look at my code here, this is code from over a year ago so I don't really remember exactly my entire solution so spatial awareness for me here was key to extracting truths to simplify the problem dramatically well guys, that's the end of the video thanks for watching if you enjoyed it if you didfound it a little useful be sure to give me a thumbs up if you didn't enjoy it hey give me a thumbs down that still counts towards participating and that still helps me boost my channel subscribe if you like share it with your friends who are interested in these puzzles as I said all my solutions are available online if you want to support this channel please consider becoming a patron patreon link in the description box below and guys if you want to join this community discord link in the description box below if you want to book me one on one, if you want to talk to me, calendar link in the description box below, and if you would like to email me if you want to marry me, divorce me, hate me, love me.
Go ahead and email me at thecodingjesus codingjesus.com thanks for watching this video guys cheers.
If you have any copyright issue, please Contact