How I made a bot that helps me solve leetcode problems

Mykhailo Kushnir
Level Up Coding
Published in
4 min readMar 19, 2023

--

Regis AI | Interview Assistant

With the recent development of large language models, there was no way that I would not have tried to create something on top of them. One particular problem that seemed too obvious to tackle was LeetCode problem solving — a standard method to interview preparation. In this blog post, I'm going to share the following:

  • How I've developed Regis Chatbot;
  • Why did I agree to meet 15 people from Reddit to conduct mock interviews for them;
  • How I asked the most popular YouTuber in the LeetCode community for promotion;

48 Hours Proof-of-Concept

I developed Regis in the spirit of my other quick hustles, some of which I've described in this blog. Minimal coding, using platforms that fit well for the idea and dirty UI are done mostly by accepting Copilots' suggestions. My initial line of thinking was:

  • People would not go to other sites to use something they need for LeetCode, so the extension fits well;
  • I don't need too much backend, so either Azure function or AWS lambdas are the perfect options;
  • I don't know React or any of the modern frameworks that kids use these days, so vanilla JS it is.

Here's what the 1.0.0 looked like:

Regis 1.0.0

The only feature of the bot was to capture the description of the problem where the user landed and push it to GPT-3 to get some actionable hints. While openai product is not particularly good at solving these problems, it seems pretty good at suggesting ways to solve them. For example, here's what it indicates in the case of a "hard" problem "Median of two sorted arrays."

Talk to Users

…And then the wall hit me. The initial statistics of the product were not looking like a hockey stick, and I had doubts about other ideas for development I had. So, I've decided to take the only sane path for a novice founder — talk to future users. But how to do it if you don't have a vast audience and your Twitter has 28 followers?

The answer is: give something back.

I went to Reddit and created my most popular post so far:

The outreach was unexpected. More than 15 people agreed to take part in this endeavour, so my calendar looks like this now:

Daily interviews, heh :)

Yet my biggest surprise was not how easily people subscribed to something offered by an unknown person from Reddit. The shocker was how good these people were at solving tasks and giving valuable feedback for a future product. After only three interviews, I've developed two new features that have confirmed my interest. One of which is a reminder feature — something asked long ago by LeetCode users:

Reminder request captured!

Promotion in “All-guns-blazing” style

If you want to develop something that people would use, your priority should be as follows:

  1. How to figure out what people want?
  2. How to get before the eyes of your users?
  3. How to develop what your users want?

It should not sound ignorant. People would not use a product they don’t know or want. Developing something first is a great way to get no traction at all. So that’s why after the initial wave of coding, I switched to promotion. Here’s how it went:

Can you spot where I was buying the traffic? :)

Here are some learnings to share:

  1. Paid traffic from LinkedIn and Twitter is not worth it. Mostly because these sites are bad at filtering Desktop only traffic, and Mobile is something I don’t need — it is impossible to install an extension there.
  2. Medium is still great for search engines, so it can drive traffic great. One of the previous posts achieved ~400 views and generated >20 hits to the chrome web store listing.
  3. Reddit is the best for finding your core users. Someone who’d deal with all the crap that inevitably would come in the first version. Right now I have two people sending me almost immediate feedback after each release.
Fixed now :)

My “last but not least step” was to email the NeetCode — a popular YouTuber in the LeetCode community that has a few hundred thousand of subscribers now. As I mentioned above, I like the strategy of “give something back”, so my initial offer to him was to create an additional feature for his site for free. It would look like an additional option for every problem listed in his educational plan:

Easy integration

If you’d like to know how this story would go on and what NeetCode would answer it (or would he simply ignore it) — then hit that subscribe button ;)

--

--