Weekend Programming Challenge Issue-18 – Console Text Editor


Image

Problem: create simple text editor for VT100 terminal

Many of us remember Borland’s Turbo Pascal V3.0 which in 39K had compiler, linker, run-time library and minimal WordStar type text editor.

BAS-INT is freeware tiny Basic interpreter with the bare minimum for BASIC scripting language. It works with external files only and is with Basic Stamp like syntax.

The Challenge today is to write minimal console editor which to complement BAS-INT and to perform some very basic commands:

List – list the program in memory with numbers
Delete N(-M) – deletes line N or N to M from memory
Insert N – inserts line on number N
Run – runs the BASIC program in memory (this code is already available)

if one wants to make it even more advanced he may make also the
Edit N – prints the content of line N and allow it to be edited

Remember this is console application and you have just serial in and serial out, no fancy graphics and windows in this editor.

The BAS-INT template is uploaded on GitHub https://github.com/OLIMEX/WPC/tree/master/ISSUE-18/BAS-INT

The rules:

You can code the solution in any programming language (well obviously as you have to integrate BAS-INT which is written in C this any language for this problem must be C) during the weekend and have to submit it to info@olimex.com latest on Sunday July 21th.

On Monday we will upload the solutions on GitHub and review https://github.com/OLIMEX/WPC .

You can play with your real name or with nick if you want to be anonymous, we will not disclosure your personal info if you do not want to.

Good Luck and Have fun!

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: