Ai Coding Tools

How to Write Your First 100 Lines of Code with AI Assistance in 2 Hours

By BTW Team4 min read

How to Write Your First 100 Lines of Code with AI Assistance in 2 Hours

If you're a complete beginner looking to write your first lines of code, it can feel overwhelming. The thought of navigating syntax, understanding logic, and debugging can be daunting. But what if I told you that with the right AI tools, you could write your first 100 lines of code in just 2 hours? In 2026, AI coding assistants have matured, making it easier than ever to get started. Let’s break down how you can leverage these tools to kickstart your coding journey.

Prerequisites: What You Need Before You Start

Before diving in, here’s what you’ll need:

  1. A Computer: Any machine with internet access will do.
  2. A Code Editor: Install Visual Studio Code (VS Code) or use an online editor like Replit.
  3. An AI Coding Assistant: Sign up for one of the AI code generators below.
  4. Basic Understanding of Programming Concepts: Familiarity with variables, loops, and functions will help, but we’ll cover the basics.

Step 1: Choose Your Programming Language

You can choose from various languages, but for beginners, I recommend starting with Python or JavaScript. Both have extensive community support and libraries.

Tool Comparison: AI Coding Assistants

| Tool Name | Pricing | Best For | Limitations | Our Take | |-------------------|-----------------------------|------------------------------|-------------------------------------|--------------------------------| | GitHub Copilot | $10/mo | Code suggestions in VS Code | Limited to VS Code integration | We use Copilot for quick fixes | | OpenAI Codex | $0-20/mo (varies by usage) | Full project generation | Can produce verbose code | Great for generating examples | | Tabnine | Free tier + $12/mo pro | Autocompletion | Less context-aware than others | We prefer it for smaller tasks | | Replit | Free tier + $7/mo pro | Online coding with AI help | Free tier has limited features | Ideal for quick experiments | | Codeium | Free | Code suggestions | Limited language support | Good for absolute beginners | | Sourcery | Free tier + $15/mo pro | Code reviews and refactoring | Not a full coding assistant | We use it for code improvement | | Ponic | $20/mo | Automated code generation | Not suitable for complex projects | Useful for boilerplate code | | AI Dungeon | Free | Interactive coding stories | Not a traditional coding tool | Fun for exploring coding ideas | | Cogram | Free tier + $10/mo pro | Collaborative coding | Limited to specific use cases | Great for team projects |

Step 2: Set Up Your Environment

  1. Install Your Code Editor: Download and install VS Code if you haven't already.
  2. Install Your AI Tool: For example, if you're using GitHub Copilot, install the extension in VS Code.
  3. Create a New Project: Open your code editor and create a new file named hello.py or app.js.

Step 3: Start Coding with AI Assistance

Now, let’s get into the coding part. Here’s a simple example of how you might write your first lines of code with AI assistance:

  1. Write a Simple Function:

    • Type def greet(name): in your Python file or function greet(name) { in JavaScript.
    • Let the AI suggest the body of the function. For example, you can type # in Python or // in JavaScript, and the AI will suggest code.
  2. Test the Function:

    • Call your function with a name: greet("World").
    • Ask the AI how to print the output. It should suggest print(greeting) in Python or console.log(greeting) in JavaScript.
  3. Refine Your Code:

    • Use the AI to refactor your code. Type // refactor and see how it improves your code.

Troubleshooting: What Could Go Wrong

  • AI Suggests Incorrect Code: Sometimes, AI might not understand your context. If that happens, try rephrasing your request or providing more context.
  • Syntax Errors: Check for common mistakes like missing colons or brackets. Most code editors will highlight these errors.

Step 4: Expand Your Codebase

Once you’ve written the initial 100 lines, consider adding more functionality. For instance, you can create a simple calculator or a to-do list app. Use the AI tool to generate code snippets for each feature you want to add.

What's Next?

After you've written your first 100 lines, keep coding! Explore new concepts like loops, conditionals, and data structures. Consider building a small project to reinforce what you've learned.

Conclusion: Start Here

Getting started with coding doesn’t have to be intimidating. With the right AI tools, you can write your first 100 lines of code in just 2 hours. Choose an AI coding assistant that fits your needs, set up your environment, and start experimenting.

Remember, the key is to keep practicing and building. You can always refine your skills over time.

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

10 AI Coding Tools That Will Drastically Reduce Your Debugging Time

10 AI Coding Tools That Will Drastically Reduce Your Debugging Time As a developer, whether you're just starting out or have years of experience, debugging can feel like a neverend

Oct 16, 20265 min read
Ai Coding Tools

10 Common Mistakes When Integrating AI Coding Tools into Your Workflow

10 Common Mistakes When Integrating AI Coding Tools into Your Workflow As developers, we’re always on the lookout for ways to streamline our workflow and boost productivity. Enter

Oct 14, 20264 min read
Ai Coding Tools

5 Myths About AI Coding Tools That Could Hurt Your Development Process

5 Myths About AI Coding Tools That Could Hurt Your Development Process As a solo founder or indie hacker, you might be lured by the promises of AI coding tools that claim to simpli

Oct 13, 20264 min read
Ai Coding Tools

5 Common Mistakes Developers Make When Using AI Coding Tools in 2026

5 Common Mistakes Developers Make When Using AI Coding Tools in 2026 As AI coding tools have become an integral part of a developer's toolkit in 2026, many are still stumbling over

Oct 12, 20264 min read
Ai Coding Tools

5 Myths About AI Coding Tools: What Every Developer Should Know in 2026

5 Myths About AI Coding Tools: What Every Developer Should Know in 2026 As we dive into 2026, the landscape of AI coding tools has evolved significantly, yet many developers still

Oct 11, 20263 min read
Ai Coding Tools

Why AI Coding Assistants Are Overrated for Beginners in 2026

Why AI Coding Assistants Are Overrated for Beginners in 2026 As a solo founder or indie hacker, it’s tempting to think that AI coding assistants are the silver bullet to jumpstart

Oct 10, 20263 min read