Using BYTE's to represent Letters
ASCII, EBCDIC, ANSI
Now, how does the computer show us letters on the screen? The most popular and universal standard is called "ASCII", which assigned letters to certain combinations of bits within a byte. So, each byte can represent one letter.
Since there are 256 possible combinations with a byte, and there are only 52 letters in our alphabet (26 lower case and 26 upper case) we easily can represent all the letters, and all the special characters with one byte.
NOTE: IBM's EBCDIC is similar to ASCII, but is all but dead right now. ANSI is still used, particularly for keyboard assignments with terminal emulator programs.
ASCII (American Standard Code for Information Interchange)
- see also http://www.asciitable.com/ - contains ASCII, Extended ASCII, EBCDIC, IBM scan codes, and HTML with friendly "&" codes
The standard ASCII character set consists of 128 decimal numbers ranging from zero through 127 assigned to letters, numbers, punctuation marks, and the most common special characters. The Extended ASCII Character Set also consists of 128 decimal numbers and ranges from 128 through 255 representing additional special, mathematical, graphic, and foreign characters.
Remember, the 8 bits can be converted to decimal number, which range from 0 to 255. For example, I will now type ALT-168, ok, here goes: ¿ Quite an unusual character!! Now let me type an ASCII decimal equivalent that is an actual key on your keyboard - I will now type ALT-107, which should be a lower case "k", ok here goes: k - great, it worked (of course).
When you type a "k" on your keyboard, you see a k appear on the screen. What you don't see is that the keyboard sends a byte into the PC, which represents a k. That byte can be found on various ASCII charts, as decimal 107, or in binary (one byte), 01101011:
01101011 = 0 128's + 1 64's + 1 32's + 0 16's + 1 8's + 0 4's + 1 2's + 1 1's = 107
So as far as your keyboard, computer, and monitor is concerned, 01101011 is a "k".
*** scroll down for ASCII, Extended ASCII, and EBCDIC Tables
We all need to insert special characters, or symbols, into our documents from time to time. Many just give up and type the word in (for example, 10 cents). But you should do it the right way - here's how for the most common symbols. For uncommon symbols, view the charts. The two most common character sets are:
ASCII code - for text and word processor documents - hold down the Alt key and type the 4-digit code, then release the Alt key)
HTML code - for web pages - paste the code into the HTML view of the web page, not the Normal view !!
HTML by default supports the character set ISO-8859-1 or Latin-1. Windows and virtually all Windows-based HTML editors use Windows-1252 which is basically the same as ISO-8859-1.
How to insert Symbols into your Document (Notepad, Word, HTML, etc.)
Here is how to create the few symbols that are more common. There is a full table of them Here.
In general, although HTML has different combinations than ASCII symbols - you can use the same ASCII code for HTML except you precede it with two characters: &#, and if the ASCII code has a leading zero, you drop it with HTML.
use of HTML shortcuts such as &trade and © are not well supported
across the browsers !!! Although this has gotten much more ubiquitous with
the newer versions of browsers lately. Here are the most common symbols:
symbol ™ : ASCII Alt-0153 - HTML: ™ or &trade
Registered Trademark Symbol ® : ASCII Alt-0174 - HTML ® OR ®
Copyright Symbol © : ASCII Alt-0169 - HTML © OR ©
Cent Symbol ¢ : ASCII Alt-0162 - HTML ¢
Short Dash – (en-dash) : ASCII Alt-0150 - HTML – OR &ndash
Long Dash — (em-dash) : ASCII Alt-0151 - HTML (4 ways):
–– (two successive short dashes)
― (do not use this - it is safest to use 8212)
NOTE: some "fancy" fonts do not have the en and em dash characters, but all you need to do is to change fonts for the dash only. There are 3 dash characters.
dash - the normal dash from your keyboard
en-dash - the slightly longer dash
em-dash - the longest dash
The following tables list ASCII, Extended ASCII, and EBCDIC (Extended Binary Coded Decimal Interchange Code):
ASCII Character set (0-127)
Extended ASCII Set (128-255)
EBCDIC (Extended Binary Coded Decimal Interchange Code)