GithubHelp home page GithubHelp logo

how-to-do-x's Introduction

I want to do "X"

The following is a guide for how to get started with programming side projects. If something's missing and you know about it, feel free to submit a pull request and add it.

Mobile Apps

Linux

Machine Learning

Security

Desktop apps

Video Games and Computer Graphics

Frontend Web

Backend Web

Infastructure and AWS

Building Programming Languages

Overview

Building languages is not as hard as it may appear! In general, the key concepts are:

  • Grammars, or the formal structure of a language.
  • Lexing, or the conversion of text into abstract "tokens" that can be used in the grammar. For example, most languages convert the + into a PLUS token.
  • Parsing, or the conversion of "tokens" (pieces of a language) into an Abstract Syntax Tree.

First Steps

A good first project is to build a calculator that can compute things like this:

1 + 2 * 5

Step 1: Write a grammar

You should probably write this in EBNF form. It doesn't need to have the exact same syntax, but it's useful to understand the conventions.

To get you started, here's a partial grammar for the calculator:

add: add '+' add | NUM.
NUM: [0-9].

Notice that grammars are written as recursive "rules". In the example above, the string 1 + 2 would enter the add rule, then recurse till it matched the NUM.

Step 2:

Learning specific programming languages

Ruby

C++

Functional Programming

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.