Can You Win The SQL Squid Game? |
Written by Nikos Vaggalis | |||
Friday, 21 February 2025 | |||
Squid Game is a free challenge inspired by the popular Netflix series with the same name. Instead of engaging in bloodthirsty games, you progress to the next level by solving SQL puzzles. The story goes as follows: You've just been hired as a Data Scientist by the mysterious Squid Game organization...the Front Man puts a gun to your head and starts demanding answers to various business questions. You must write SQL queries to answer him – or else. And you must do that by progressively completing all 9 Levels. Let's look into what the challenges actually look like, starting with Level 1. Your first challenge begins now: You've joined just at the right time – the first game of Red Light, Green Light finished and we've generated some fresh data to analyze and fresh bodies to harvest. The organizers want to identify vulnerable living players who might be easily manipulated for the next game. Find all players who are alive, in severe debt (debt > 400,000,000 won), and are either elderly (age > 65) OR have a vice of Gambling with no family connections. To aid you in the quest, you'll be supplied with the Schema, two Hints, and the Solution in case things go awry. You can have as many attempts as you like, and when you're certain you got it, you just fill the form named "Enter your solution" at which point it will check and notify you if your solution is ok or wrong. If wrong you can try again until you finaly get it. As far level 1, it might sound easy but in reality it is a bit tricky. The solution is as follows: Next level, 2, is more difficult : The organizers need to calculate how many food portions to withhold to create the right amount of tension. In a table, calculate how many rations would feed 90% of the remaining(alive) non-insider players (rounded down), and in another column, indicate if the current rations supply is sufficient. (True or False) The expected result is : Needed rations->329, Has enough rations->true, and the suggested solution was : While I arrived at the same solution but from a different path, that of CTE: the platform wasn't accepting it which makes me suspicious that it might require the same SQL as predefined by the solution for it to succeed? Of course with each subsequent level, the difficulty increases. Can you finish them to get the prize money? To wrap it up, the game is intriguing, brain teasing and perfect for data analysts to hone their skills. More InformationRelated ArticlesThe Advent of SQL 2024 Has Commenced
To be informed about new articles on I Programmer, sign up for our weekly newsletter, subscribe to the RSS feed and follow us on Twitter, Facebook or Linkedin.
Comments
or email your comment to: comments@i-programmer.info |