We found the Google Secret Hiring Coding Challenge

We found the Google Secret Hiring Coding Challenge

google secret code challenge rabbit animation

Recently, we stumbled upon a secret coding challenge hidden within a Google search. As we conducted the search, the results page slid and fell back to reveal an invitation to the challenge. Intrigued, we accepted the invitation and embarked on a journey to solve the mystery. In this article, we will share our experience and the details of the challenge with you. Keep reading to learn more.

If you want to try triggering the Easter egg for yourself, you can follow the steps we took. Start by searching Google for various technical terms, such as the name of a programming framework or a specific programming concept. We managed to recreate the process by searching for the term 'List Comprehensions' in Python, and it worked after we had conducted about a dozen searches. It's worth noting that on our second attempt, the Easter egg appeared after we searched for 'list comprehensions' three times in a row.

sercret google foobar coding challenge

You are presented with this invitation:

Curious developers are known to seek interesting problems. Solve one from Google?

You can respond with

  • I want to play
  • No thanks
  • Don't show me this again

You get a terminal/shell in the browser with a few commands which will be familiar to anyone who has used the Linux shell.

Typing help will give you a list of available commands.

Command Description
cd change directory [dir_name]
cat print file [file_name]
deleteme delete all of your data associated with foobar
edit open file in editor [file_name]
feedback provide feedback on foobar
less print a file a page at a time [file_name]
ls list directory contents [dir_name]

We are given a set of encryption rules and two example encrypted sentences. The challenge is to code the decryptor. If you're interested here are the instructions that we were given:

I Love Lance & Janice
---------------------

You've caught two of your fellow minions passing coded notes back and forth -- while they're
on duty, no less! Worse, you're pretty sure it's not job-related -- they're both huge 
fans of the space soap opera "Lance & Janice". You know how much commander
Lanbda hates waste, so if you can prove these minions are wasting time passing non-job-related
notes, it'll put you that much closer to promotion.

Fortunately for you, the minions aren't exactly advanced cryptographers. In their code, every 
lowercase letter [a..z] is replaced with the corresponding one in [z..a], while every other 
character (including uppercase letters and punctuation) is left untouched. That is, 'a'
becomes 'z', 'b' becomes 'y', 'c' becomes 'x', etc.  For
instance, the word ""vmxibkgrlm"", when decoded, would become 
""encryption"".

Write a function called solution(s) which takes in a string and returns the deciphered string so you 
can show the commander proof that these minions are talking about ""Lance 
& Janice"" instead of doing their jobs

Languages
========

To provide a Python solution, edit solution.py
To provide a Java solution, edit Soltion.java

Test cases

Your code should pass the following test cases. Note that it may also be run against hidden test cases not shown here.

--cases --

Input: 
solution.solution("wrw blf hvv ozhg mrtsg'h vkrhlwv?")
Output: 
did you see last night's episode?

To preserve the excitement of the challenge, we have decided not to publicly share our solution. However, if you are interested in seeing how we approached the problem and would like to learn more about our solution, please let us know. We will be happy to provide a link to a private video that demonstrates our solution and provides an explanation of our thought process.

Finally, we submitted our program and it worked. We were met with a cute bunny!

google bunny animation