Skip to content
View easycoder's full-sized avatar

Block or report easycoder

Block user

Prevent this user from interacting with your repositories and sending you notifications. Learn more about blocking users.

You must be logged in to block users.

Please don't include any personal information such as legal names or email addresses. Maximum 100 characters, markdown supported. This note will be visible to only you.
Report abuse

Contact GitHub support about this user’s behavior. Learn more about reporting abuse.

Report abuse
easycoder/README.md

Introduction

This is the Python version of EasyCoder, a high-level English-like scripting language suited for prototyping and rapid testing of ideas. It operates on the command line.

The JavaScript version of EasyCoder, which provides a full set of graphical features to run in a browser, is at https://easycoder.github.io

Quick Start

1: Install EasyCoder in your Python environment:

pip install easycoder@git+https://github.com/easycoder/easycoder.git

2: Write a test script, 'test.ecs':

print `Hello, world!`

This is traditionally the first program to be written in virtually any language. To run it, launch Python and type the following commands:

from easycoder import Program
Program(['test.ecs'])

The script is passed in as a list because it could be just one of a number of command-line arguments.

The output will look like this:

Compiled <anon>: 1 lines (2 tokens) in 0 ms
Run <anon>
1-> Hello, world!

To avoid having to use REPL you can set up a simple command such as this bash script, calling it test.py:

#!/bin/python3

from easycoder import Program
Program(['test.ecs'])

When given execute permission this runs as ./test.py. In the repository there is an ecrun.py script that if placed in your working directory and given execute permission will run any EasyCoder file. In this case the command would be ./ecrun.py test.ecs.

It's conventional to add a program title:

!   Test script

    script Test

    print `Hello, world!`

The first line here is just a comment and has no effect on the running of the script. The second line gives the script a name, which is useful in debugging as it says which script was running. The output is now

Compiled Test: 5 lines (4 tokens) in 0 ms
Run Test
5-> Hello, world!

As you can guess from the above, the print command gives the line in the script it was called from. This is very useful in tracking down debugging print commands in large scripts.

Also in the repository is benchmark.ecs; a test program containing many of the EasyCoder features. To see it running use the command ./ecrun.py benchmark.ecs.

The EasyCoder programming language

There are three primary components to the language: 1 Keywords 2 Values 3 Conditions

All program lines start with a keyword - a command to EasyCoder to do something

(Under construction)

Pinned Loading

  1. easycoder easycoder Public

    A version of the EasyCoder scripting language, written in Python

    Python

  2. easycoder.github.io easycoder.github.io Public

    A version of the EasyCoder scripting language, written in pure vanilla JavaScript for browsers

    JavaScript 2

  3. pie pie Public

    Programming in English

    JavaScript

  4. storyteller storyteller Public

    A template for static websites using extended markdown to create content

    Python 1

  5. webson webson Public

    Using JSON to represent the DOM

    JavaScript

  6. rbr rbr Public

    Room By Room Heating - a home heating project using low-cost microcontrollers and computing modules.

    PHP