Visit brilliant.org/TedEd to check out Brilliant’s 60+ courses in math, logic, science, and computer science. They feature storytelling, code-writing, interactive challenges, and plenty of puzzles for you to solve. And as an added bonus, the first 833 of you to use that link will receive 20% off the annual premium subscription fee.
I don't know how friendly the other particles can be if their idea of fun is Mutually Assured Destruction. Personally I would accelerate so much into the other direction that I become the first photon.
"you are a particle floating through the space..." "If you're lucky, you will become a seed for a future galaxy..." I wasn't expecting an existential crisis over a riddle
I took 1 minute and 37 seconds. My strategy was similar to the one at the end of the video. It doesn't really matter how many anti-matter particles are to your left, and thus, you should maximize the number of anti-matter particles in a sequence to your left, and maximize the number of matter particles to your right. That removes a ton of the starting positions already, just compare the ones remaining and make sure that the number of matter particles minus anti-matter particles equals 0. Thankfully, this is one puzzle that I am actually able to solve.
I'm with dignity and honour announcing to Ted Ed and groups that this is the only riddle I'm able to solve after so many years to facing hardships to even understand the solution of riddles (〒﹏〒)
How? I guess you haven't watched all the series or you've become way better, because there were extremely easy riddles before, like the virus and the robot ants. This was fairly complicated.
I recognized the strategy within 30 seconds! I realized that the condition was standing to the left of another antiparticle, and not to the right led to anihilation, so I reasoned that finding the longest string of gluons and standing to the leftmost position will leave only you standing. Typically though, I can't figure these questions out, so that made me very happy!
this doesn't work. imagine 2, -1, 5, -4, 1, -3 setup. with your logic, you'd stand left to 5, but you would still get destroyed, as the correct answer is standing left to 2
I thought something similar I think, have the longest string of antimatter particles on your left - and it makes sense why this would work sometimes, but I tried a couple more situations & figured out it wouldn't always work
Loved this one. For the second riddle, you create a pair of coordinates. First represent position, second a "total". Where you start is 0, 0. From then, you add 1 for every matter encountered. Add -1 for every antimatter encountered. You continue until your sum go below zero or you complete the circle. If you complete the circle without going negative any moment, that's a safe spot. If you get negative, it means that the position where you went negative and all previous positions (included the spot you choose) are not safe.
My strategy for the end was to pick a random spot, add and subtract around the circle as shown, and keep track of the lowest number reached and where it was. I'll stand exactly where the lowest number was reached. Tied lowest numbers are all valid. Don't need to test all spaces, just one test around the circle is enough.
yes!! this was how I thought about it too. important clarification when you're talking about programming a device :) don't want to have to repeat your program 50,000+ times
Solving the first part took me definitely less than a minute. I did not time it unfortunately, but here's how I did it: A viable position is always characterized by an antimatter particle followed by a matter particle (counter-clockwise/right direction). Reason: if you position yourself left of an antimatter particle, you immediately annihilate; if you position yourself right of a matter particle, this particle will never annihilate before you, since the annihilation occurs to the right. Then it's a matter of counting (if you're a machine) or pattern matching (if you're good at that): If matter particles are +1 and antimatter particles -1, go through the ring summing them up counter-clockwise from your chosen position. If the sum never goes below 0 => you found a winning position. For the code: point the device at any position x we will denote this position as 0 (x = 0) assuming the "order of particles" is an array, where index 0 is the first particle to the right of the chosen position x While x < number of particles (there are as many positions as particles): (we'll call this loop1) if the first particle in the sequence (right of x) is antimatter: increment x continue with the next iteration of loop1 if the last particle in the sequence (left of x) is matter: increment x continue with the next iteration of loop1 set n = 0 set sum = 0 while n < number of particles: (loop2) if particle at position n is matter: add 1 to sum else if the particle at position n is antimatter: subtract 1 from sum if add < 0: increment x continue with the next iteration of loop1 increment n (if loop2 completes successfully:) break out of loop1 and return position x as safe OR if the goal is to find all safe positions: save/print value of x, increment x, continue with next iteration of loop1
I didn’t take much time to fully double check, but I think ur idea can still be simplified. Consider what would happen if you moved the starting position one to the right. The entire circle’s “states” would all increase or decrease by 1 depending on if you just shifted over a matter or antimatter. Considering the lack of true change in states, we can simply just start anywhere. Run the calculations and choose the spot with the lowest value. The logic being that we can always shift the starting spot to the “lowest state” and now every state will be positive. Might be wrong though didn’t double check
@@P0is0ndagger127 Hmm, do you mean something like this: (beginning at any particle in the ring) n = 0 sum = 0 min_sum = 0 safe_positions = variable-size array [] while n < number_of_particles: if particle at position n is matter: sum = sum + 1 else if the particle at position n is antimatter: sum = sum - 1 if sum < min_sum: min_sum = sum overwrite safe_positions with [n] else if sum == min_sum: append n to safe_positions increment n => positions right after/to the right of any particle in safe_positions is safe
@@P0is0ndagger127 I thought of the same strategy and it works. As for implementation, you don't even need to store the min value, just change the sum back to 0: sum = 0 safe_positions = [-1] for pos, type in particles: sum += type == matter ? 1 : -1 if sum == -1: sum = 0 safe_positions = [] if sum == 0: append pos to safe_positions
Part 1 took about 60 seconds for me. I found a simple algorithm to find safe spots: pick any particle in the circle and label it "1". Now traverse the circle from that particle by going right. If you are visiting a matter particle, label it one more than the previous particle. Otherwise, label it one less. Continue until every particle has a label. The safe spots are to the right of all particles that share the smallest value. I used mspaint on a screenshot of the puzzles to label the particles which sped things up a lot. The safe-unsafe checker will likely do something similar: traverse to the right from your starting position, starting at the value 0. Add one if you see matter, subtract one if you see anti-matter. If you ever end up in the negatives, the spot isn't safe. If you get back to your starting position, it's safe.
Wow. I’m just going to say that this is the only riddle I’ve managed to actually understand and solve after 2 years of watching TED Ed. I was so proud of myself haha
If you have ever been trained for the Olympiad in Informatics, the riddle will seem much less difficult. In fact, the core concept of it is what we called "prefix sum" method. The riddle itself is interesting, and if we take a further step like asking ourselves "What'll happen if two matters of cube annihilate with only one antimatter of cube", we'll find ourselves observing the question at a higher level.
My algorithm to always find the spot: start your counting and go leftwards(clockwise) around the circle (from anywhere with zero). For every anti matter you encounter subtract 1 and for every matter add 1. When you go arround you are bound to get to zero (the number you started with). Now the best place to stand is to the left of the particle with the highest positive score. Haven't seen the actual solution but I'm positive about this one.
A point worth mentioning is that this method is actually more efficient than the one mentioned in the video. This is because firstly it lets you know of the safe spots just by assigning numbers once. The equivalence of both the results is found by realizing that if I had started my counting from the maximum then since it is an extremum the curve made would lie completely below the 0 point and hence would never hit zero. Note: The maximum will only be one point after you add a +1 to a shared maximum spot by adding your matter particle over there.
Are we not gonna talk about the fact that these particles were created into a chaotic new universe and the first thing they did was create a death game
4:02 minutes. My strategy was look for the amount of antimatter to the right of matter. Be the one in the last spot to get eliminated so long as the antimatter to the left of you has an equal number of matter to the left of it
My solution was to choose a random spot between a matter and anti-matter cube (anti-matter to the left of matter), begin summing while counting clockwise (minus for anti-matter, plus for matter) until I hit a spot which fulfills the conditions: - count is zero - spot is between an antimatter and a matter cube That means the device should be programmed to count until it hits zero THEN minus 1 and declare the spot previous to it safe More efficient but complicated
My strategy before unpausing: choose any matter particle and assign it value 0. Moving clockwise, add one if matter or subtract one if antimatter. Keep track of which particle had the highest value seen thus far. The spot to the left of that particle is safe. If you see a big group of matter particles, the rightmost one is a good starting point (making negative values less likely). You could actually assign any starting value; only the relative differences matter. If the max value appears multiple times, there are multiple safe spots. Finally, you can end early if you're sure the current max value can't be surpassed. For my fellow nerds, this algorithm is O(n).
My strategy was basically: 1) Pick a random spot was was to the right of antimatter and the the left of matter. 2) Check left pretty much doing the +-1 thing. 3a) If I got a +1 aka a matter to my left, I repeat step 1 to the next spot to that matter's left that meets the conditions. 3b) If i go through the whole circle without reaching +1 and end up with a 0, thats my spot.
Another way to look at this is starting from any position and moving towards the right step by step and keeping in track the number of antimatter and matter cubes separately, we can see that any instant the number of matter cubes must be greater than or equal to no of antimatter cubes(also counting the cube itself from where we start) for that spot to be a valid position. If at any instant no of antimatter cubes becomes more, then that spot is not a solution. +1, -1 approach was a bit nicer though.
Start at any particle and go left and count particles. Matter particles are counted up and antimatter counted down. Each time you count a particle, you assign them that number. After assigning every particle with a number, insert yourself left of the highest number. For example if we start at top left for this circle: --++-- + + + + --+--+ We count and assign numbers assign numbers as follows: -1 -2 -1 0 -1 -2 0 -1 -1 0 -2 -1 0 -1 0 1 So the best place to insert yourself will be left of the matter particle on the bottom right.
As a developer, this is like tracking stacks of bracket pairs on an arbitrarily long line that loops back on itself and trying to find out what's the outermost scope :D Doing the +1, -1 and taking the spot with the minimum value does the trick.
Start from each matter particle and count the particles going clockwise. If at no point there is more antimatter than matter, you can go to the starting particle's immediate (counterclockwise) left.
5:10 No need to do it for every spot. Just pick a spot at random and start the running sum. See where that running sum hits minima. That minima will have antimatter at one side and matter on the other. Just sit between those two particles.
I thought they proposed a murder mystery where we had to figure whether it was Leonard, Howard, Raj, Penny, Bernadette, or Amy that finally snapped and killed Sheldon.
You can make the program more effiecient to tell you the correct spot without check each one individually If you start counting from 0 from any given spot subtracting 1 at anti matter and adding 1 at matter simply find the spot which has the lowest value and you know it will be safe. As you know that if you counted from that value the number would never go down
I did both riddles, i always loved these riddles man its so nostalgic 💗💗 my first was the bridge riddle, it was like around 6 years ago. I did the challenge in 6:30 nice and easy
This riddle reminds me a lot about the STACK data structure. On the circle, when performing the *sum*, every time you add 1 its like pushing something to it, and every time you subtract 1 its like popping something, if the stack ever gets empty then its not a safe spot
I know this is slightly late, but I took a slightly different approach. I selected any point on the circle at random (without myself in it), and begin to count anti-clockwise, with a + adding 1, and a - subtracting 1. The difference with my approach was that I calculated the value at which the most negative value was calculated. When I was done with the circle, I would simply move to the space that had the most negative value calculated. To use the safe method, I would do something as follows: Pick any gap between two particles at random. Set lowest number seen to be -1 -- Loop starts here While counting in a clockwise direction: If sum is lower than the lowest number we've ever seen, print safe. Then record that number as the lowest number ever seen. Select the point that the minimum occurred and loop again. Else if there is no sum that is lower than the number we've ever seen, then this point is the safest point. Stay here, and stop looping. -- Loop ends here. Thought it was a fun way to solve. Thanks for the challegne :D
I introduce a counter starting at zero and choose a random spot, then I move to the spot to its immediate left if I pass an antimatter particle I lower the counter by 1 if I pass a matter particle I raise it by one then I continue to move to the next spot to the left until I reach my original spot once I circled the entire circle I choose my spot as the one where the counter was the highest
No need to repeat the calculation for each possible starting spot. Just start anywhere and keep adding/removing 1 until you are back where you started. As there are the same number of matter and antimatter cubes, the running count will be back to zero. The safe spot is next to the maximum value ever reached by the running count (there may be ties). By the way, based on the video, it’s likely all attendees are now dead. Annihilation is much more efficient than nuclear fusion or fission, and standing near a blast of hard gamma radiation in such large amounts, depending on the distance, will vaporize the attendees, crush them in the ensuing pressure wave, or give them radiation sickness.
Scanning every possible insertion point, where at each point makes +1/-1 through the whole ring would take O(n^2) time. However, we can pick any insertion point as a starting point (don't insert yourself into that point yet). Mark that starting point to have sum = 0. Run through the whole ring once, calculate accumulate sum of +1/-1 of each step. Every time the sum get lower than the previous seen sum, update that spot to be a candidate. After finish running through the whole ring, the candidate spot is the point of insertion. This algorithm run in O(n).
You can think of it as sets of brackets cancelling out, where a (+) is an opening bracket and a (-) is a closing bracket. So the sum hitting zero means that the next bracket that will be matched is you, because you’re on the zeroth level.
3:45 run through the sequence to your right. +1 for glouns, -1 for antimatter. As you go down the sequence if you ever get to negative the spot is unsafe
I had come up with a slightly different method. start with sum = 0. index clockwise from any point. If the current cube is matter, add one, if it is antimatter, subtract one. Keep a value for the maximum sum you've seen so far and the index at which it was seen. If the sum is greater than or equal to the previous max, save the new max value and the index where you reached it. After one cycle, your safe spot is one spot clockwise from the stored index. It doesn't matter which cube you choose to index as the first, it will always work.
I first had a bad strategy but it kind of worked for the three initial examples, I pick a spot, draw an imaginary line that goes trhough the center of the circle and divides it in two, then check that the portion at my left has more antimater than the portion at the right. Then i realized that it doesn´t have to work but it was a fast way to visually pick a candidate spot.
43 seconds, strategie was combining 4 things that are needed 1. anti immigetly to left 2. the amount of anti to the left needs to be >= the amount of glutons to the left of the antimather. 3.Gluton to the immigetly right. 4.The amount of gluton to the right needs to be >= the amount of anti to the right of them. whit this alot of spots dissappear immigetly, so by trying a spot in the head that followed these rules there is high chance it works. the first two circles I got whit the first spot guess while the last circle needed two guesses to find the correct spot.
1 minute 16 seconds, yay. For the second question, pick a point, and move to the right until you reach the start again. For each matter, increase the "buffer particles" by 1, for each antimatter, decrease it by 1. If the buffer goes negative before it completes the loop, it's unsafe. Otherwise, it's safe. edit: Close enough, my take starts at zero and can't go negative, instead of starting at +1 and can't be 0.
had a couple minute think about a strategy only to conclude that i couldn't find a 100% foolproof trick and decided on winging it with one piece of strategy; to go the furthest left of which there are the most amount of normal matter to my right. That actually really helped as i solved all three in under a minute total using a slightly varied approach after actually seeing the circles, which was to go as far right as possible of which there are the most amount of anti matter to my left, pretty much the same thing but slightly different, to be exact it took me 56 seconds, pretty happy with it!
I tried to find some kind of trick for it, but it turns out there isn't one... you literally have to count particles, starting from each point to the left (clockwise) of a group of + ones, to see if you'd make it all the way around without running out of buffer. When there's a small number of them, you can sort of do that by intuition or grouping, but it's effectively the same process.
actually the program solution doesnt seem time effective because you have to calculate all ~54k spots for sum of 54k cells of +1 and -1. 54^2 might be too big. On the other hand. if you choose a random spot and calculate 54k then choose one of the highest points(there can be multiple, which means mulitple safe spots) during the summing process. you need only 108k actions (whether a spot is highest or not is an actions too). So you save like a few days of calculation time(54k*54k/ 1k action per second ~ 1000 hour).
I have similar solution, but it's faster. Start from any position, count sum of matter, as in the video. Whenever sum has lowest possible value, its safe spot. As a result, we got all the safe places after going through the cycle only once.
One simplified and single traversal approach would be to only count continuous stream of particles and add yourself to the leftmost of the max length of continuous particles. You will be lastone standing
I actually used the second approach from the start and figured it out in like a minute, so it only took like 5 to 10 seconds for each ring. That's probably, because a similar concept is used in many combinatorics problems in mathematics competitions. So for me it's basically as if I've had already known the solution. But many people don't have a mathematics background like I do, so you shouldn't feel discouraged if it took you longer or you couldn't figure it out on your own. If anything I should probably do something more productive with my time instead of watching youtube. um... yeah. Thanks for listening (I mean reading, I guess) to my TED-talk.
the way I described the riddle in my head to solve it was to find a line of anti matter with a line of matter next to them, then stand behind them and push them to annihilate each other like a long conga line chain. I don't know why I chose the word conga line, but if it works, it works.
Being a matter particle, I will program my device to find a spot: n. Such that the particle to the right of n is a matter particle and that to the left is an antimatter particle.
Maybe it's just me but in the past, all of these riddles stumped me. This time, it seemed mind numbingly obvious off the bat because it's just finding pairs to shield you. I'm not even sure how this is a riddle it's just a math concept/addition and subtraction. First time I've been underwhelmed by one of these...
So, we used to be regular people, then wildebeest, then pilgrims, then vampire hunters, then sausage spies, then cannonballs, and now we’re just particles. I’m not Camilo, Ted-Ed, i can’t shapeshift.
Different way: chose a matter particle and count all particles on his right side till the amount of counted matter particles equals the amount of antimatter particles. Do this for the next matter particle after your stop, and so on. If u finished, place yourself before the matter particle with the highest number
I didn't start a timer but it took me around 30 seconds. My strategy was to start by writing the circle as a long binary number. Like the first one was 1110110000. Then I crossed off any 0 followed by a 1. Repeat till last pair remains then you stand to the right of the last 1.
For the First Part i only had the rule "stand to the right of a Antimatter particle and left of a Matter particle" and then eyeballed it in 15 Seconds. Second Part: find every possible starting Position right of a Antimatter and left of a Matter particle. Have a counter that Starts at 0 If it gets at any Point into the negativ this Position doesnt work For each starting Position: Loop: Go 1 to the right. If its a Matter add 1 to the counter. If its antimmater subtract 1. Loop end If you Go trough the whole circle without ever having the counter negativ. The Position is save
Took me about 3 seconds to pick my spots based on my strategy, which was a fairly simple “always be to the left of the longest line of mater because I figured all shorter lines would fully deplete before your longer line. I realize after the fact that there could be a case where two shorter line are divided by just 1 antimatter and could combine after the first round to be longer. Taking this into consideration and spending another 2-3 seconds looking at the rings I still like my original spots. Time to see how I did.
I found better solution than presented at 5:33. Testing multiple places until you find "no hitting zero" configuration is a waste of time. There are thousands places to test. Do below instead: Start counting at any spot. Find the lowest sum you hit in whole circle. Stand on the right to that point. If there are multiple points with the same number each of them is safe. That way you need to sum circle only once instead of counting for each point. That's actually my strategy used for original question at 1:15. Example (-1 is antimatter, 1 is matter): 1,1,1,1,-1,-1,-1,1,-1,1,1,-1,-1,1,-1,-1,1,1,-1,-1. The sum will be 1,2,3,4,3,2,1,2,1,2,3,2,1,2,1,0,1,2,1,0. Your spot is safe because 0 is lowest number and you are standing next to it. There is also another safe spot 4 places before your. Now start counting from next position, you will get: 1,2,3,2,1,0,1,0,1,2,1,0,1,0,-1,0,1,0,-1,0. You are standing next to 0 (and you'll always be) but the lowest number is now -1 so safe spot is 1 place before your and 5 places before you. Which makes sense because we started counting 1 place on the right. If we started counting from 4th position you would get only negative numbers and 0 at the end. The lowest number would be -4 and it'd on the same safe place as in counting before. Why it works? Whenever you move to another place either each "subsum" is increased or decreased by the same number. The lowest/highest numbers will be still lowest/highest, the difference between any two numbers will be the same.
My solution : start with any matter cube as +1, and go on summing up all cubes with matter as +1 and anti matter as -1. After completely scanning all cubes, the spots with most negative sum will be the safe ones.
Took me about 15 seconds to figure it out, but I only got the second one right. My strategy was to just be exactly to the left of fthe biggest number of matter particles
Surely the most efficient strategy is to scan the whole circle from one starting point and pick a point just at the right to the minimum value of the partial sums.
Get in between antimatter and matter partial in such a way that the antimatter is on the left, and highest number of matter particles are to the right.
The solution should be: 1. start from a random position, reset counter to zero 2. move from left to right and +1/-1 counter base on matter/anti-matter 3. record the position and the minimum value when the counter find its new minimum. 4. loop through all position, the right side of the position with minimum counter is the position you should start with.
This is a Turing odd/even problem. I chose to complete it by labeling antimatter as 0 and matter as 1. 1. Pick a starting point 2. Go right until a 1 is found. Mark that 1 with the number of steps it took to get there from the starting point. Let's say 3. 3. Go right from 3 until you find a 0. Mark that 0 by the number of steps since the starting point. Let's say 5. 4. 3 and 5 are now paired off and can be skipped (usually referred to with an X) 5. Go back to the start. Go right until you find a 1 and not a 0 or an X. 6. Repeat steps 2-5, pairing everything off. Eventually, it will be all Xs. 7. Go to the right of the last paired 0.
I came up with this simple logic, you need to position yourself in the circle so that the anti-matter is right next to you in the clockwise direction and there is the longest line of normal matter in the circle right next to you in the anti-clockwise direction. I came with this by observing the first demonstration animation of how the game goes
In the first half, you said "these are the safe spots" - safe spots PLURAL. But only one is truly safe, the other "safe spots" won't be because only one will remain, so it's not like "Oh pick one of these and you'll be fine." I would just go to the leftmost position of the largest line of matter…
To make it more efficient, start at one spot and keep track of where the sum was the least. If the sum is always positive, that's a safe spot. Else, pick any spot where the sum was the least at.
Visit brilliant.org/TedEd to check out Brilliant’s 60+ courses in math, logic, science, and computer science. They feature storytelling, code-writing, interactive challenges, and plenty of puzzles for you to solve. And as an added bonus, the first 833 of you to use that link will receive 20% off the annual premium subscription fee.
It is very informative
"Stand to the left of the biggest patch of antimatter" was my strategy
reallly?
Very nice. Danks.
@@leo_the_cow u very nice
"Pick a spot to stand where you won't be annihilated." Every middle school dance and workplace birthday "party" I've ever been to.
I never comment on comments but for some reason this one made me laugh.
🤣
my mind immediately went to sh..tings
@@j-r-m7775 you're too busy getting gains to comment
This is dangerously relatable
I didn't expect to start my day with an existential crisis over a riddle. Thanks Ted Ed :D
Tell us you're antimatter without telling us you're antimatter.
Ah, it's fine. None of the matter or anti-matter was at all sentient so no one got hurt in the super hot mess at the start of the universe.
@@DemPilafian i am extremely complex & maybe doesn't exist
@@DemPilafian i'm already gone
@@DemPilafian You're antimatter without telliing us you're antimatter.
This is a pretty messed up idea for a game if you think about it, but I guess intergalactic ethics standards were different back then
cosmic suicide game
Russian roulette with all but one chamber filled. 😱
i mean like especially since they all just started existing like damn give it a few days first
Stop spoiling Squid Game season 2.
stuff like this would never hold up in front of intergalactic ethics boards today
I don't know how friendly the other particles can be if their idea of fun is Mutually Assured Destruction.
Personally I would accelerate so much into the other direction that I become the first photon.
I wonder why the phrase 'Mutually Assured Destruction' has been popping up so much lately... weird :/
@@speedyboi1471 haha Ukraine go boom funni
Thereby skipping the annihilation parts, remember photons are pure energy.
@@arushjain1103 what
@@moo8866 I was joking but I actually support Ukraine.
"you are a particle floating through the space..."
"If you're lucky, you will become a seed for a future galaxy..."
I wasn't expecting an existential crisis over a riddle
5:36 That face of pure joy watching your own brethren VIOLENTLY EXPLODE AGAINST ONE ANOTHER
LOL
@@Arkos.Knightis your name?!😂😹😸😁😆😄😉
True story
I took 1 minute and 37 seconds.
My strategy was similar to the one at the end of the video. It doesn't really matter how many anti-matter particles are to your left, and thus, you should maximize the number of anti-matter particles in a sequence to your left, and maximize the number of matter particles to your right. That removes a ton of the starting positions already, just compare the ones remaining and make sure that the number of matter particles minus anti-matter particles equals 0. Thankfully, this is one puzzle that I am actually able to solve.
Yeah, I think is is one of the easiest, if not the easiest riddle so far.
Im not even smart enough to understand the rules
I took 21 sec to find the same strategy
Yeah this one was quite easy i too got the strategy tho only at the last(meaning when pausing for the second one i got it)
I also came up with this same strategy pretty quickly
I'm with dignity and honour announcing to Ted Ed and groups that this is the only riddle I'm able to solve after so many years to facing hardships to even understand the solution of riddles
(〒﹏〒)
How? I guess you haven't watched all the series or you've become way better, because there were extremely easy riddles before, like the virus and the robot ants. This was fairly complicated.
@@veryrandomhandle i can say from experience that it is harder than it looks for me
Did you see the ant riddle? That one was easy.
I recognized the strategy within 30 seconds! I realized that the condition was standing to the left of another antiparticle, and not to the right led to anihilation, so I reasoned that finding the longest string of gluons and standing to the leftmost position will leave only you standing. Typically though, I can't figure these questions out, so that made me very happy!
That doesn't work for the 24-particle circle though, right? Or the 10-particle circle, actually.
this doesn't work. imagine 2, -1, 5, -4, 1, -3 setup. with your logic, you'd stand left to 5, but you would still get destroyed, as the correct answer is standing left to 2
I see, looks like I still didn't figure it out. Looks like Ted-Ed is still too smart for me after all lol
I thought something similar I think, have the longest string of antimatter particles on your left - and it makes sense why this would work sometimes, but I tried a couple more situations & figured out it wouldn't always work
Someone beat me to it 1 year earlier... but there is no guarantee that he is still alive today...perhaps i am the one that still survive?😂
Never thought I’d be a particle going through such a roller coaster
Loved this one.
For the second riddle, you create a pair of coordinates.
First represent position, second a "total".
Where you start is 0, 0.
From then, you add 1 for every matter encountered.
Add -1 for every antimatter encountered.
You continue until your sum go below zero or you complete the circle.
If you complete the circle without going negative any moment, that's a safe spot.
If you get negative, it means that the position where you went negative and all previous positions (included the spot you choose) are not safe.
My strategy for the end was to pick a random spot, add and subtract around the circle as shown, and keep track of the lowest number reached and where it was. I'll stand exactly where the lowest number was reached. Tied lowest numbers are all valid.
Don't need to test all spaces, just one test around the circle is enough.
I did the same ❤️ ..
yes!! this was how I thought about it too. important clarification when you're talking about programming a device :) don't want to have to repeat your program 50,000+ times
Well, your solution is a magnitude better than the O((0.5n)²) ones
“… then that spot is safe”
*big flashing arrow points to most obviously unsafe antimatter arc in the entire ring*
5:31
Solving the first part took me definitely less than a minute. I did not time it unfortunately, but here's how I did it:
A viable position is always characterized by an antimatter particle followed by a matter particle (counter-clockwise/right direction).
Reason: if you position yourself left of an antimatter particle, you immediately annihilate; if you position yourself right of a matter particle, this particle will never annihilate before you, since the annihilation occurs to the right.
Then it's a matter of counting (if you're a machine) or pattern matching (if you're good at that):
If matter particles are +1 and antimatter particles -1, go through the ring summing them up counter-clockwise from your chosen position. If the sum never goes below 0 => you found a winning position.
For the code:
point the device at any position x
we will denote this position as 0 (x = 0)
assuming the "order of particles" is an array, where index 0 is the first particle to the right of the chosen position x
While x < number of particles (there are as many positions as particles): (we'll call this loop1)
if the first particle in the sequence (right of x) is antimatter:
increment x
continue with the next iteration of loop1
if the last particle in the sequence (left of x) is matter:
increment x
continue with the next iteration of loop1
set n = 0
set sum = 0
while n < number of particles: (loop2)
if particle at position n is matter:
add 1 to sum
else if the particle at position n is antimatter:
subtract 1 from sum
if add < 0:
increment x
continue with the next iteration of loop1
increment n
(if loop2 completes successfully:)
break out of loop1 and return position x as safe OR
if the goal is to find all safe positions: save/print value of x, increment x, continue with next iteration of loop1
I like your funny words magic man
I didn’t take much time to fully double check, but I think ur idea can still be simplified.
Consider what would happen if you moved the starting position one to the right. The entire circle’s “states” would all increase or decrease by 1 depending on if you just shifted over a matter or antimatter.
Considering the lack of true change in states, we can simply just start anywhere. Run the calculations and choose the spot with the lowest value.
The logic being that we can always shift the starting spot to the “lowest state” and now every state will be positive.
Might be wrong though didn’t double check
@@P0is0ndagger127 Hmm, do you mean something like this:
(beginning at any particle in the ring)
n = 0
sum = 0
min_sum = 0
safe_positions = variable-size array []
while n < number_of_particles:
if particle at position n is matter:
sum = sum + 1
else if the particle at position n is antimatter:
sum = sum - 1
if sum < min_sum:
min_sum = sum
overwrite safe_positions with [n]
else if sum == min_sum:
append n to safe_positions
increment n
=> positions right after/to the right of any particle in safe_positions is safe
@@TheDisasterMo something like that, at least if it works it would save some time
@@P0is0ndagger127 I thought of the same strategy and it works. As for implementation, you don't even need to store the min value, just change the sum back to 0:
sum = 0
safe_positions = [-1]
for pos, type in particles:
sum += type == matter ? 1 : -1
if sum == -1:
sum = 0
safe_positions = []
if sum == 0:
append pos to safe_positions
Part 1 took about 60 seconds for me. I found a simple algorithm to find safe spots: pick any particle in the circle and label it "1". Now traverse the circle from that particle by going right. If you are visiting a matter particle, label it one more than the previous particle. Otherwise, label it one less. Continue until every particle has a label. The safe spots are to the right of all particles that share the smallest value. I used mspaint on a screenshot of the puzzles to label the particles which sped things up a lot.
The safe-unsafe checker will likely do something similar: traverse to the right from your starting position, starting at the value 0. Add one if you see matter, subtract one if you see anti-matter. If you ever end up in the negatives, the spot isn't safe. If you get back to your starting position, it's safe.
I'd though of the same, but it only took me like 10-20sec because instead of counting I "estimated" the points that are safe
Exactly, find the min value. This is an O(n) algorithm compared to an O(n²) solution in the video
Wow. I’m just going to say that this is the only riddle I’ve managed to actually understand and solve after 2 years of watching TED Ed. I was so proud of myself haha
If you have ever been trained for the Olympiad in Informatics, the riddle will seem much less difficult. In fact, the core concept of it is what we called "prefix sum" method. The riddle itself is interesting, and if we take a further step like asking ourselves "What'll happen if two matters of cube annihilate with only one antimatter of cube", we'll find ourselves observing the question at a higher level.
My algorithm to always find the spot: start your counting and go leftwards(clockwise) around the circle (from anywhere with zero). For every anti matter you encounter subtract 1 and for every matter add 1. When you go arround you are bound to get to zero (the number you started with). Now the best place to stand is to the left of the particle with the highest positive score. Haven't seen the actual solution but I'm positive about this one.
Note that if you encounter a maximum twice (or more), then it shouldn't matter, stand to the left of any of the maximums and you should survive.
This is how I solved it, I think is the easiest way. I did prove it with the 3 examples and it worked perfectly :)
This is exactly how I solved it. Feels great reading my exact thoughts on a comment written by someone else. 😄👍
Funny that I found someone who also used this method.
A point worth mentioning is that this method is actually more efficient than the one mentioned in the video. This is because firstly it lets you know of the safe spots just by assigning numbers once. The equivalence of both the results is found by realizing that if I had started my counting from the maximum then since it is an extremum the curve made would lie completely below the 0 point and hence would never hit zero. Note: The maximum will only be one point after you add a +1 to a shared maximum spot by adding your matter particle over there.
Are we not gonna talk about the fact that these particles were created into a chaotic new universe and the first thing they did was create a death game
4:02 minutes. My strategy was look for the amount of antimatter to the right of matter. Be the one in the last spot to get eliminated so long as the antimatter to the left of you has an equal number of matter to the left of it
My solution was to choose a random spot between a matter and anti-matter cube (anti-matter to the left of matter), begin summing while counting clockwise (minus for anti-matter, plus for matter) until I hit a spot which fulfills the conditions:
- count is zero
- spot is between an antimatter and a matter cube
That means the device should be programmed to count until it hits zero THEN minus 1 and declare the spot previous to it safe
More efficient but complicated
My strategy before unpausing: choose any matter particle and assign it value 0. Moving clockwise, add one if matter or subtract one if antimatter. Keep track of which particle had the highest value seen thus far. The spot to the left of that particle is safe.
If you see a big group of matter particles, the rightmost one is a good starting point (making negative values less likely). You could actually assign any starting value; only the relative differences matter. If the max value appears multiple times, there are multiple safe spots. Finally, you can end early if you're sure the current max value can't be surpassed.
For my fellow nerds, this algorithm is O(n).
I had the exact same strategy, but reversed: moving anti-clockwise, keep track of the lowest value, stand in the spot right of that particle. 👍
Even I did the same
Looking for someone who did it like this in comments section :D
This was the best story behind a riddle….scientific story+mathematical riddle
Isn't this basically the Josephus problem but with particles?
My strategy was basically:
1) Pick a random spot was was to the right of antimatter and the the left of matter.
2) Check left pretty much doing the +-1 thing.
3a) If I got a +1 aka a matter to my left, I repeat step 1 to the next spot to that matter's left that meets the conditions.
3b) If i go through the whole circle without reaching +1 and end up with a 0, thats my spot.
If you store the block where the minimum value is, you can immediately output the safe spot
Another way to look at this is starting from any position and moving towards the right step by step and keeping in track the number of antimatter and matter cubes separately, we can see that any instant the number of matter cubes must be greater than or equal to no of antimatter cubes(also counting the cube itself from where we start) for that spot to be a valid position. If at any instant no of antimatter cubes becomes more, then that spot is not a solution. +1, -1 approach was a bit nicer though.
Yeah, and from a programming standpoint, it’s neater, since you only have to keep track of one variable, and you have a fixed point to compare to.
@@samuelding7854 Yup
4:07 “Russian doll of fundamental particles “ Definitely not the sentence I expected to hear today 😂
Start at any particle and go left and count particles. Matter particles are counted up and antimatter counted down. Each time you count a particle, you assign them that number. After assigning every particle with a number, insert yourself left of the highest number.
For example if we start at top left for this circle:
--++--
+ +
+ +
--+--+
We count and assign numbers assign numbers as follows:
-1 -2 -1 0 -1 -2
0 -1
-1 0
-2 -1 0 -1 0 1
So the best place to insert yourself will be left of the matter particle on the bottom right.
As a developer, this is like tracking stacks of bracket pairs on an arbitrarily long line that loops back on itself and trying to find out what's the outermost scope :D Doing the +1, -1 and taking the spot with the minimum value does the trick.
You can start anywhere from 0, and going clockwise add 1 for every particle, subtract 1 for antiparticle. Each maximum is a safe spot.
Except... each *_minimum_* is a safe spot. ;-)
Start from each matter particle and count the particles going clockwise. If at no point there is more antimatter than matter, you can go to the starting particle's immediate (counterclockwise) left.
5:10 No need to do it for every spot. Just pick a spot at random and start the running sum. See where that running sum hits minima. That minima will have antimatter at one side and matter on the other. Just sit between those two particles.
I came to the comments to say this is the missing step to the solution (finding the minimum).
I thought they proposed a murder mystery where we had to figure whether it was Leonard, Howard, Raj, Penny, Bernadette, or Amy that finally snapped and killed Sheldon.
You can make the program more effiecient to tell you the correct spot without check each one individually
If you start counting from 0 from any given spot subtracting 1 at anti matter and adding 1 at matter simply find the spot which has the lowest value and you know it will be safe. As you know that if you counted from that value the number would never go down
I did both riddles, i always loved these riddles man its so nostalgic 💗💗 my first was the bridge riddle, it was like around 6 years ago.
I did the challenge in 6:30 nice and easy
This riddle reminds me a lot about the STACK data structure. On the circle, when performing the *sum*, every time you add 1 its like pushing something to it, and every time you subtract 1 its like popping something, if the stack ever gets empty then its not a safe spot
I know this is slightly late, but I took a slightly different approach.
I selected any point on the circle at random (without myself in it), and begin to count anti-clockwise, with a + adding 1, and a - subtracting 1. The difference with my approach was that I calculated the value at which the most negative value was calculated. When I was done with the circle, I would simply move to the space that had the most negative value calculated.
To use the safe method, I would do something as follows:
Pick any gap between two particles at random.
Set lowest number seen to be -1
-- Loop starts here
While counting in a clockwise direction:
If sum is lower than the lowest number we've ever seen, print safe.
Then record that number as the lowest number ever seen.
Select the point that the minimum occurred and loop again.
Else if there is no sum that is lower than the number we've ever seen, then this point is the safest point. Stay here, and stop looping.
-- Loop ends here.
Thought it was a fun way to solve. Thanks for the challegne :D
Normally, I’m barely smart enough to understand the solution when it’s explained. This time I actually figured it out on my own.
I introduce a counter starting at zero and choose a random spot, then I move to the spot to its immediate left
if I pass an antimatter particle I lower the counter by 1
if I pass a matter particle I raise it by one
then I continue to move to the next spot to the left until I reach my original spot
once I circled the entire circle I choose my spot as the one where the counter was the highest
No need to repeat the calculation for each possible starting spot. Just start anywhere and keep adding/removing 1 until you are back where you started. As there are the same number of matter and antimatter cubes, the running count will be back to zero. The safe spot is next to the maximum value ever reached by the running count (there may be ties).
By the way, based on the video, it’s likely all attendees are now dead. Annihilation is much more efficient than nuclear fusion or fission, and standing near a blast of hard gamma radiation in such large amounts, depending on the distance, will vaporize the attendees, crush them in the ensuing pressure wave, or give them radiation sickness.
Minimum value, not maximum value
Scanning every possible insertion point, where at each point makes +1/-1 through the whole ring would take O(n^2) time. However, we can pick any insertion point as a starting point (don't insert yourself into that point yet). Mark that starting point to have sum = 0. Run through the whole ring once, calculate accumulate sum of +1/-1 of each step. Every time the sum get lower than the previous seen sum, update that spot to be a candidate. After finish running through the whole ring, the candidate spot is the point of insertion. This algorithm run in O(n).
You can think of it as sets of brackets cancelling out, where a (+) is an opening bracket and a (-) is a closing bracket. So the sum hitting zero means that the next bracket that will be matched is you, because you’re on the zeroth level.
3:45 run through the sequence to your right. +1 for glouns, -1 for antimatter. As you go down the sequence if you ever get to negative the spot is unsafe
I had come up with a slightly different method. start with sum = 0. index clockwise from any point. If the current cube is matter, add one, if it is antimatter, subtract one. Keep a value for the maximum sum you've seen so far and the index at which it was seen. If the sum is greater than or equal to the previous max, save the new max value and the index where you reached it. After one cycle, your safe spot is one spot clockwise from the stored index. It doesn't matter which cube you choose to index as the first, it will always work.
I first had a bad strategy but it kind of worked for the three initial examples, I pick a spot, draw an imaginary line that goes trhough the center of the circle and divides it in two, then check that the portion at my left has more antimater than the portion at the right. Then i realized that it doesn´t have to work but it was a fast way to visually pick a candidate spot.
43 seconds, strategie was combining 4 things that are needed
1. anti immigetly to left
2. the amount of anti to the left needs to be >= the amount of glutons to the left of the antimather.
3.Gluton to the immigetly right.
4.The amount of gluton to the right needs to be >= the amount of anti to the right of them.
whit this alot of spots dissappear immigetly, so by trying a spot in the head that followed these rules there is high chance it works. the first two circles I got whit the first spot guess while the last circle needed two guesses to find the correct spot.
*strategy *immediately *gluon *with *a lot. :-B
I love these. I mean, I can’t solve them, but it’s cool to see the solution as if I did.
1:34 every TED-ED riddle goes "let's work backwards from the result"
01:15 love that Analog Synthesizer sound 😍
This reminds me of the Josephus problem which numberphile did a great video on
Holy moly Brilliant shells out sponsorship money. I wish I could get some of that!
1 minute 16 seconds, yay.
For the second question, pick a point, and move to the right until you reach the start again. For each matter, increase the "buffer particles" by 1, for each antimatter, decrease it by 1.
If the buffer goes negative before it completes the loop, it's unsafe. Otherwise, it's safe.
edit: Close enough, my take starts at zero and can't go negative, instead of starting at +1 and can't be 0.
Muito obrigado pela tradução Mafalda e Margarida!
had a couple minute think about a strategy only to conclude that i couldn't find a 100% foolproof trick and decided on winging it with one piece of strategy; to go the furthest left of which there are the most amount of normal matter to my right. That actually really helped as i solved all three in under a minute total using a slightly varied approach after actually seeing the circles, which was to go as far right as possible of which there are the most amount of anti matter to my left, pretty much the same thing but slightly different, to be exact it took me 56 seconds, pretty happy with it!
I tried to find some kind of trick for it, but it turns out there isn't one... you literally have to count particles, starting from each point to the left (clockwise) of a group of + ones, to see if you'd make it all the way around without running out of buffer. When there's a small number of them, you can sort of do that by intuition or grouping, but it's effectively the same process.
Kimari, thank you. I tried this for over an hour, and I also found no strategy.
actually the program solution doesnt seem time effective because you have to calculate all ~54k spots for sum of 54k cells of +1 and -1. 54^2 might be too big. On the other hand. if you choose a random spot and calculate 54k then choose one of the highest points(there can be multiple, which means mulitple safe spots) during the summing process. you need only 108k actions (whether a spot is highest or not is an actions too). So you save like a few days of calculation time(54k*54k/ 1k action per second ~ 1000 hour).
The first full riddle video I got right! :))
Genius
Usually most of us don't get it but still watch the video till the end cause we love TED ed
Haven't seen it yet, but it looks fascinating as always!
I have similar solution, but it's faster. Start from any position, count sum of matter, as in the video. Whenever sum has lowest possible value, its safe spot. As a result, we got all the safe places after going through the cycle only once.
4 min to solve all! Thanks TED-Ed!
Ted Ed, can we have easy riddles or puzzles like your very first one? The zombie crossing bridge one?
One simplified and single traversal approach would be to only count continuous stream of particles and add yourself to the leftmost of the max length of continuous particles. You will be lastone standing
I actually used the second approach from the start and figured it out in like a minute, so it only took like 5 to 10 seconds for each ring. That's probably, because a similar concept is used in many combinatorics problems in mathematics competitions. So for me it's basically as if I've had already known the solution. But many people don't have a mathematics background like I do, so you shouldn't feel discouraged if it took you longer or you couldn't figure it out on your own. If anything I should probably do something more productive with my time instead of watching youtube. um... yeah. Thanks for listening (I mean reading, I guess) to my TED-talk.
“The ring is to large to simulate annihilations like before, but luckily, you have an Iphone you have use to check which particales have green eyes.”
the way I described the riddle in my head to solve it was to find a line of anti matter with a line of matter next to them, then stand behind them and push them to annihilate each other like a long conga line chain. I don't know why I chose the word conga line, but if it works, it works.
I miss these riddles :D
This reminds me of the Josephus problem
Being a matter particle, I will program my device to find a spot: n. Such that the particle to the right of n is a matter particle and that to the left is an antimatter particle.
Maybe it's just me but in the past, all of these riddles stumped me. This time, it seemed mind numbingly obvious off the bat because it's just finding pairs to shield you. I'm not even sure how this is a riddle it's just a math concept/addition and subtraction. First time I've been underwhelmed by one of these...
So, we used to be regular people, then wildebeest, then pilgrims, then vampire hunters, then sausage spies, then cannonballs, and now we’re just particles. I’m not Camilo, Ted-Ed, i can’t shapeshift.
I actually did the final solution just like they did. That’s a first I wasn’t expecting
Different way: chose a matter particle and count all particles on his right side till the amount of counted matter particles equals the amount of antimatter particles. Do this for the next matter particle after your stop, and so on. If u finished, place yourself before the matter particle with the highest number
I didn't start a timer but it took me around 30 seconds. My strategy was to start by writing the circle as a long binary number. Like the first one was 1110110000. Then I crossed off any 0 followed by a 1. Repeat till last pair remains then you stand to the right of the last 1.
For the First Part i only had the rule "stand to the right of a Antimatter particle and left of a Matter particle" and then eyeballed it in 15 Seconds.
Second Part: find every possible starting Position right of a Antimatter and left of a Matter particle.
Have a counter that Starts at 0 If it gets at any Point into the negativ this Position doesnt work
For each starting Position:
Loop:
Go 1 to the right. If its a Matter add 1 to the counter.
If its antimmater subtract 1.
Loop end
If you Go trough the whole circle without ever having the counter negativ. The Position is save
Took me about 3 seconds to pick my spots based on my strategy, which was a fairly simple “always be to the left of the longest line of mater because I figured all shorter lines would fully deplete before your longer line. I realize after the fact that there could be a case where two shorter line are divided by just 1 antimatter and could combine after the first round to be longer. Taking this into consideration and spending another 2-3 seconds looking at the rings I still like my original spots. Time to see how I did.
Well, looks like that only worked on the second circle. My quick double check was off by one pair.
I found better solution than presented at 5:33. Testing multiple places until you find "no hitting zero" configuration is a waste of time. There are thousands places to test. Do below instead:
Start counting at any spot. Find the lowest sum you hit in whole circle. Stand on the right to that point. If there are multiple points with the same number each of them is safe. That way you need to sum circle only once instead of counting for each point. That's actually my strategy used for original question at 1:15.
Example (-1 is antimatter, 1 is matter): 1,1,1,1,-1,-1,-1,1,-1,1,1,-1,-1,1,-1,-1,1,1,-1,-1. The sum will be 1,2,3,4,3,2,1,2,1,2,3,2,1,2,1,0,1,2,1,0. Your spot is safe because 0 is lowest number and you are standing next to it. There is also another safe spot 4 places before your.
Now start counting from next position, you will get: 1,2,3,2,1,0,1,0,1,2,1,0,1,0,-1,0,1,0,-1,0. You are standing next to 0 (and you'll always be) but the lowest number is now -1 so safe spot is 1 place before your and 5 places before you. Which makes sense because we started counting 1 place on the right.
If we started counting from 4th position you would get only negative numbers and 0 at the end. The lowest number would be -4 and it'd on the same safe place as in counting before.
Why it works? Whenever you move to another place either each "subsum" is increased or decreased by the same number. The lowest/highest numbers will be still lowest/highest, the difference between any two numbers will be the same.
My solution : start with any matter cube as +1, and go on summing up all cubes with matter as +1 and anti matter as -1. After completely scanning all cubes, the spots with most negative sum will be the safe ones.
Start the sum from any point. Mark cumulative sum for each point, then all the points where sum is minimum (max negative), are the safe spots.
At the end, I like how he’s smiling when he’s ‘enjoying the fireworks’.
According to the Big Bang theory, the expansion of the observable universe began with the explosion of a single particle at a definite point in time.
According to the Big Bang theory, all whole universe was in a hot dense state, then nearly fourteen billion years ago expansion started. Wait...
There was nothing to "explode" in a way that is similar to what we would call "explosion"
Took me about 15 seconds to figure it out, but I only got the second one right. My strategy was to just be exactly to the left of fthe biggest number of matter particles
This strategy doesn't work. You can see the first circle at 1:27 would put you in a losing spot.
So did you actually figure it out? I don't get it.
I got the first one in, like, a minute and I'm so happy because this is the first riddle I've actually gotten lol
Surely the most efficient strategy is to scan the whole circle from one starting point and pick a point just at the right to the minimum value of the partial sums.
I'm a kid and I love Ted Ed riddles!
Thanks for the Challanged Version. It took mee 1:26 minute to get all 3.
First riddle: Oh I solved, I'm so smart
Second riddle: let's not talk about the second riddle
For the second riddle I thought of summing up all matter particles (N) and anti-matter particles (F) separately and stepwise. If at any point N
(0:37) Cosmic Whistle sounds like the name of a low-class alcohol brand.
Get in between antimatter and matter partial in such a way that the antimatter is on the left, and highest number of matter particles are to the right.
The solution should be:
1. start from a random position, reset counter to zero
2. move from left to right and +1/-1 counter base on matter/anti-matter
3. record the position and the minimum value when the counter find its new minimum.
4. loop through all position, the right side of the position with minimum counter is the position you should start with.
“Can you solve the Big Bang riddle?”
Me: “no. But I like watching the answer!”
well i just like watching the whole story
Before the explanation of what's happening is complete, the gluon looks terrifying but after, it looks like the cutest thing in existence
This is a Turing odd/even problem. I chose to complete it by labeling antimatter as 0 and matter as 1.
1. Pick a starting point
2. Go right until a 1 is found. Mark that 1 with the number of steps it took to get there from the starting point. Let's say 3.
3. Go right from 3 until you find a 0. Mark that 0 by the number of steps since the starting point. Let's say 5.
4. 3 and 5 are now paired off and can be skipped (usually referred to with an X)
5. Go back to the start. Go right until you find a 1 and not a 0 or an X.
6. Repeat steps 2-5, pairing everything off. Eventually, it will be all Xs.
7. Go to the right of the last paired 0.
This sounds just like last month's birthday cake riddle.
I came up with this simple logic, you need to position yourself in the circle so that the anti-matter is right next to you in the clockwise direction and there is the longest line of normal matter in the circle right next to you in the anti-clockwise direction. I came with this by observing the first demonstration animation of how the game goes
That won't necessarily work depending on how long strings of consecutive antimatter are, though
this is similar to a problem numberphile covered some time ago about a circle of warriors killing the odd numbered ones to their right
Imagine being one of the ANTIparticles who can’t do anything about being annihilated.
In the first half, you said "these are the safe spots" - safe spots PLURAL. But only one is truly safe, the other "safe spots" won't be because only one will remain, so it's not like "Oh pick one of these and you'll be fine." I would just go to the leftmost position of the largest line of matter…
To make it more efficient, start at one spot and keep track of where the sum was the least. If the sum is always positive, that's a safe spot. Else, pick any spot where the sum was the least at.
What’s to stop the antimatter’s from going the other way when YOU’re standing next to them?