Videos
I have to prepare for interviews and I am using free version of Strata Search and paid version of Leetcode to get the hang of it. Please let me know if that’s enough. My goal is to practice 2-4 medium and hard questions everyday and start giving interviews for next week. Appreciate any tip and help.
I’m not sure how many people in this sub use Python, but I wanted to share this program because it allowed me to practice all 125 LeetCode (LC) database/SQL problems in an efficient way.
Background- the two problem I wanted to solve:
-
Majority of SQL problems on LC are locked
-
Even with access to the problem, creating the query can be challenging without being able to test and output the intermediate queries that make up the final solution.
My initial solution was manually copying and pasting the tables from LC to db-fiddle.com, but then I thought, there must be a better way- that is how this program was conceived.
What this Python program does:
Using the web automation package Selenium, it opens the LC problem selected by the user, parses the table data, and creates the table schema in db-fiddle so that you can test your queries. Additionally, it saves all the db-fiddles you've been working on in case you want to continue working on them in future sessions.
Sample outputs (for question #1369):
problem statement tab: https://leetcode.jp/problemdetail.php?id=1369
db-fiddle tab: https://www.db-fiddle.com/f/oMDnFch8BXL45r3dUVF17V/0
solutions tab: https://github.com/kamyu104/LeetCode-Solutions/blob/master/MySQL/get-the-second-most-recent-activity.sql
Demo and GitHub link:
Check it out on GitHub: https://github.com/jjjchens235/leetcode-sql-unlocked
Not to be a spoil sport, but it could probably be construed as copyright infringement.
Just thought I'd mention it in case you're concerned about that sort of thing.
I was browsing leetcode sql problems 10 seconds ago and was thinking like most of them are locked and this post popped up.
Hello,
I have written my first blog post in medium about what I have learned solving leetcode SQL problems. Shared some tips for those who want to start solving SQL problems too.
Also added some resources in the post which might be beneficial for you.
Happy reading!
https://medium.com/@iamrafiul/what-i-have-learned-by-solving-almost-all-the-sql-problems-in-leetcode-670b8a2cb32e