ASCII (American Standard Code for Information Interchange) is a standard for (digital) encoding of text. It can hold a range of 255 characters. These include the english alphabet (uppercase and lowercase), numbers, commons symbols in sentences, and a few control characters (text operators). It was approved as an ANSI standard in 1963.

It assigns a 7-bit code to each basic text character, which gives it a room of 128 characters. The extra bit creates a room for extending ASCII by another 128 characters, e.g. ISO 8859 - a standard that extends ASCII with european/cyrillic characters.

ASCII has been designed to make working with encoding easier. All whitespace and text-editing characters are first until 0100000, roughly followed by numbers, uppercase and lowercase letters. Numbers start at 0110000.

110000 110001 110010 110011...
   0      1      2      3     

The difference between each uppercase and lowercase is exactly 32 bits. Only a single digit in their encoding has to be changed:

100100 --> 110100
   D         d   

For its simplicity and inability to represent characters of less common alphabets, it is often replaced with more complex encodings such as UTF-8. These are almost always backwards compatible with ASCII, and ASCII itself is supported everywhere.


ASCII Rendering

image of fish


 @ @%%%%@
@#@*   +*@
@*++   @+@
@*++    +@
@#@*    *@
 @ @%%%%@

ASCII rendering means generating/converting a bitmap image to ASCII using an algorithm that converts pixels to specific ASCII characters based on their color and alpha values. Example of palette (from white to black): .:-=+*#%@.

ASCII-generated: Mandelbrot set, Text banner


           /    ';_      
    .     (  0 _/  "-._  
    |\     \_ /_==-"""'  
    | |:---'   (         
     \ \__."    ) Steamer
      '--_ __--'    Duck!

ASCII art is the art of creating graphics and images only out of fixed-width ASCII characters (manually, unlike simple ASCII conversion/generation). It was used in early Internet communities for reasons imposed largely by the limitations of old computers -- it could be created easily with a text editor and saved in pure text format, it didn't take much space to store or send over a network and it could be displayed on text-only displays and terminals. The principle itself predates computers, people were already making these kinds of images with typewriters. ASCII images can be made improvisationally out of shapes, using every character the 256-range allows, or they can be made using an ASCII palette, directly substituting color in pixels. Ex. 1: #OVaxsflc/!;,.- . Ex. 2: WM0KXkxocl;:,'. . An ASCII diagram may be embedded e.g. in a comment in a source code to explain a spatial concept. ASCII art is a great lower bandwith alternative to pixel art.

Hearts, Table, Graph, ROFLcopter, World map

Binary, Pixel, Standard