This preview shows pages 1–2. Sign up to view the full content.
This preview has intentionally blurred sections. Sign up to view the full version.
View Full Document
Unformatted text preview: Strings and Languages A string is simply the concatenation of several letters in an alphabet. Typically, we will define an alphabet as a set . So, for example, we could have = {a,b}. Then, a string over this alphabet , would be any word formed with only the letters or characters a and b. There is no limit on the length of a string. It must simply be a non negative integer. This means there is a string of length of length 0. This is known as the empty string. The empty string is typically denoted by . In particular, if you concatenate the empty string with any other string, you get back that string. It seems silly to have an empty string, but it will help out in certain situations. Make sure you do not confuse the empty string with the empty set. Also, recognize that can never be a letter of an alphabet. In the book, they define nonempty strings in the following manner : n is a string of length n over the alphabet , and is defined as below: 1) 1 = . 2) n+1 = {xy  x , y n } And any string is simply a subset of n , where n is a positive integer. Using the books definition, we can define the following two...
View
Full
Document
This document was uploaded on 06/09/2011.
 Fall '09

Click to edit the document details