Ai Coding Tools

How to Use GitHub Copilot to Write Your First 50 Lines of Code in 30 Minutes

By BTW Team3 min read

How to Use GitHub Copilot to Write Your First 50 Lines of Code in 30 Minutes

If you're a solo founder or indie hacker, you're likely juggling many tasks at once, and coding can feel like a daunting mountain to climb. Enter GitHub Copilot, an AI-powered code assistant that can help you write code faster and with less hassle. The best part? You can get your first 50 lines of code down in about 30 minutes. Sounds too good to be true? Let's break it down step-by-step.

Prerequisites: What You Need to Get Started

Before diving into GitHub Copilot, here’s what you need:

  1. GitHub Account: Free to sign up.
  2. Visual Studio Code (VS Code): Download and install it from here.
  3. GitHub Copilot Subscription: As of June 2026, it costs $10/month after a free trial.
  4. Basic Understanding of Coding: Familiarity with programming concepts will help, but you don’t need to be a pro.

Step 1: Install GitHub Copilot

  1. Open Visual Studio Code.
  2. Go to the Extensions view by clicking on the Extensions icon in the Activity Bar on the side.
  3. Search for "GitHub Copilot" and click "Install."
  4. Sign in to your GitHub account when prompted.

Expected Output: You should see GitHub Copilot icon enabled in the sidebar.

Step 2: Start a New Project

  1. Create a new folder for your project.
  2. Open that folder in VS Code.
  3. Create a new file, for example, app.js.

Expected Output: You should now have a blank JavaScript file ready for coding.

Step 3: Prompt GitHub Copilot

Start typing a function or a comment about what you want to achieve. For example, type:

// Function to add two numbers

Expected Output: GitHub Copilot will automatically suggest code. Press Tab to accept the suggestion.

You can repeat this process for more functions or features you want to implement.

Step 4: Write Your First 50 Lines

Here’s a quick list of code snippets you might write:

  1. Adding two numbers
  2. Subtracting two numbers
  3. A function to multiply numbers
  4. A function to divide numbers

Expected Output: You’ll have a basic calculator app with about 50 lines of code in no time.

Troubleshooting: What Could Go Wrong

  • Copilot Doesn't Suggest Anything: Make sure you're providing enough context in your comments or code.
  • Code Doesn't Work: GitHub Copilot's suggestions may not always be perfect. Test each function after acceptance and tweak as necessary.

What's Next: Building on Your Foundation

Once you’ve got your first 50 lines down, consider the following next steps:

  1. Explore More Functions: Expand your calculator with additional features like handling edge cases.
  2. Integrate with a Frontend: If you're feeling adventurous, try linking it to a simple HTML page.
  3. Learn About Testing: Start writing tests for your functions to ensure they work as expected.

Conclusion: Start Here

Using GitHub Copilot can significantly speed up your coding process and help you overcome the initial hurdles of writing code. If you're just starting, I recommend you dive into this tool and experiment with it. You'll be surprised at how quickly you can produce functional code.

In our experience, GitHub Copilot is best for solo founders and indie hackers who want to prototype quickly without getting bogged down in syntax errors or boilerplate code.

Follow Our Building Journey

Weekly podcast episodes on tools we're testing, products we're shipping, and lessons from building in public.

Subscribe

Never miss an episode

Subscribe to Built This Week for weekly insights on AI tools, product building, and startup lessons from Ryz Labs.

Subscribe
Ai Coding Tools

Cursor vs GitHub Copilot: Which AI Tool Actually Boosts Coding Speed in 2026?

Cursor vs GitHub Copilot: Which AI Tool Actually Boosts Coding Speed in 2026? As a solo founder or indie hacker, you know that time is your most valuable resource. With the rise of

Jun 7, 20263 min read
Ai Coding Tools

How to Use GitHub Copilot to Speed Up Your Coding in Just 1 Hour

How to Use GitHub Copilot to Speed Up Your Coding in Just 1 Hour If you're a solo founder or indie hacker, you know that time is your most precious resource. Every minute spent cod

Jun 7, 20264 min read
Ai Coding Tools

Codeium vs GitHub Copilot: Which AI Tool Is Right for You in 2026?

Codeium vs GitHub Copilot: Which AI Tool Is Right for You in 2026? As we dive into 2026, the landscape of AI coding tools continues to evolve, offering a plethora of options for de

Jun 7, 20264 min read
Ai Coding Tools

How to Increase Your Coding Efficiency by 50% Using AI in 30 Days

How to Increase Your Coding Efficiency by 50% Using AI in 30 Days If you're a solo founder or indie hacker, you know that time is your most valuable asset. What if I told you that

Jun 7, 20264 min read
Ai Coding Tools

Bolt.new vs Cursor: Which AI Coding Tool is Superior for Independent Developers?

Bolt.new vs Cursor: Which AI Coding Tool is Superior for Independent Developers in 2026? As independent developers, we often find ourselves juggling multiple projects while trying

Jun 7, 20263 min read
Ai Coding Tools

The $100 AI Stack for Solo Developers: Do More with Less

The $100 AI Stack for Solo Developers: Do More with Less As a solo developer, balancing budget constraints while trying to leverage the power of AI can feel overwhelming. You want

Jun 7, 20266 min read