My Experience with Google Foobar
One day when I was doing a random search with Google, I encountered a strange popup that looked like this. Out of curiosity, I clicked I…
My Experience with Google Foobar
One day when I was doing a random search with Google, I encountered a strange popup that looked like this. Out of curiosity, I clicked I want to play, which began my journey with the Google Foobar challenge.


What is it?
While some other articles on the Google Foobar challenge said that this is Google’s secret hiring process, I think you can take it for fun first. After I finished it and submitted my contact details, I did not hear anything from Google.
One possible reason is that I did not optimize the solutions. As the challenge does not enforce time and space limitations, the brute force solution will work. So if you are eager, I suggest optimizing the solution before submitting it.
How to get it?
This is by invitation only, which means that simply typing the URL will not work. You get either get it either by friend invitation or by searching for some interesting tech stuff.
Details
Problem Setting
There are 5 levels in total,
-
Level 1: 1 question
-
Level 2: 2 questions
-
Level 3: 3 questions
-
Level 4: 2 questions
-
Level 5: 1 question
It is worth mentioning that my algorithm skill level is around average technical interview level (excluding those companies test for super hard LeetCode questions), and I did not do competitive programming or math.
The questions in Level 1 and Level 2 are considerably easy. The questions in level 3 test more on basic algorithm techniques. The questions in Level 4 and Level 5 are more on the math side.
The question usually has a super long body to give you an immersive gamified experience, but most of it is not related to the question.
Questions and Solutions
Please refer to my GitHub repository
Debugging
Debugging can be the hardest part as the rest of the test cases are all hidden apart from the given test cases. Here is some clue based on my experience,
-
If failed test cases 1 & 2, it indicates some compilation error. Maybe you did not copy the full solution from your local to the shell, like the import in Java.
-
If failed other test cases, can focus on checking the noticeable corner cases and unconsidered logic. Usually, it does not indicate that it hits the memory/space limitation as I feel there is not really a limit. But for some optimization in terms of the code itself, please do. For example, when calculating GCD, using minus is much slower than using modulo.
With that, all the best for your journey with Foobar!

메타데이터
- post_id
- f73f00f7fa9f
- slug
- my-experience-with-google-foobar-f73f00f7fa9f
- url
- https://medium.com/@LIME0040/my-experience-with-google-foobar-f73f00f7fa9f
- canonical_url
- https://medium.com/@LIME0040/my-experience-with-google-foobar-f73f00f7fa9f
- author_url
- https://medium.com/@LIME0040
- status
- ok
- fetched_at
- 2026-07-25 01:02:52