Two-out-of-five code

From Wikipedia, the free encyclopedia

In telecommunication, a two-out-of-five code is a m of n code in binary-coded decimal notation in which:

  1. each decimal digit is represented by a binary numeral consisting of five bits of which two are of one kind, called "ones," and three are of the other kind, called "zeros", and
  2. the usual weights assigned to the bit positions are 0-1-2-3-6. However, in this scheme, zero is encoded as "binary" 01100; strictly speaking the 0-1-2-3-6 previously claimed is just a mnemonic device.

Source: From Federal Standard 1037C

The U.S. Post Office POSTNET barcode uses a two-out-of-five code printed in long bars for "ones" and short bars for "zeros" to represent the ZIP+4 code for automated mail sorting and routing equipment. The weights assigned to the bit positions are: 7-4-2-1-0 (Though in this scheme, zero is encoded as 11, or "binary" 11000). This method was also used in crossbar switching systems.

The IBM 7070, IBM 7072, and IBM 7074 computers used a two-out-of-five code. The bit positions were numbered 0-1-2-3-4, with no associated weights. The sign of a word could be A Alphameric, - Minus, or + Plus; using only bit positions 0-3-4.

The following table represents decimal digits from 0 to 9 in various two-out-of-five code systems:

Digit Telecommunication
01236
U.S. Post Office
74210
IBM 7070, 7072, 7074
01234
0 01100 11000 01100
1 11000 00011 11000
2 10100 00101 10100
3 10010 00110 10010
4 01010 01001 01010
5 00110 01010 00110
6 10001 01100 10001
7 01001 10001 01001
8 00101 10010 00101
9 00011 10100 00011
A N/A N/A 1––10
- N/A N/A 1––01
+ N/A N/A 0––11
Advanced Search
Included Web Search Engines


Safe Search

close

Top Matching Results

Occasionally Search.com will highlight specialized results that are based on the context of your query. Examples of specialized results include specific links to news, images, or video.

Top Matching Results may highlight information from other Search.com pages, content from the CNET Network of sites, or third party content. The listings are based purely on relevance. Search.com does not receive payment for listings in this section but our partners that provide this data may get paid for listing these products.

Sponsored Links

This section contains paid listings which have been purchased by companies that want to have their sites appear for specific search terms and related content. These listings are administered, sorted and maintained by a third party and are not endorsed by Search.com.

Search Results

Search.com sends your search query to several search engines at one time and integrates the results into one list which has been sorted by relevance using Search.com's proprietary algorithm. You can customize the list of search engines included in your metasearch from the preferences.

The search engines that are used in your metasearch may allow companies to pay to have their Web sites included within the results. To view the Paid Inclusion policy for a specific search engine, please visit their Web site. Search.com does not accept payment or share revenue with any search engine partner for listings in this section.