Assignment #3 95.204 A Nov 30/95
I AA N N RRR EEEE I DDD
I A A NN N R R E I D D
I AAAA N N N RRR EEE I D D
I A A N NN R R E I D D
I A A N N R R EEEE I DDD
223779
Table of Contents
================= Section
Program 0.1
spell.cpp 0.1
User Manual 1.0
Program info 1.1
Programmer info 1.1
Description of problem 1.2
Policy on words 1.2
Input data files 1.3
words.dat format 1.3
Program limitations 1.4
Execute instructions 1.5
Program Reference Manual 2.0
Program info 2.1
Programmer info 2.1
Description of problem 2.2
Policy on words 2.2
Data structures 2.3
Functional specification 2.4
Overall structure 2.5
testing
peusdo-code
Find a word 2.6
testing
peusdo-code
Add 2 text file 2.7
testing
peusdo-code
Query user 2.8
testing
peusdo-code
Add word to dictionary 2.9
testing
peusdo-code
Find matching words 2.10
testing
peusdo-code
Get word 2.11
testing
peusdo-code
Build dictionary 2.12
testing
peusdo-code
Display tree 2.13
testing
peusdo-code
Testing Part 1 2.14
(insert, initTree, display, searchTree, findMatchTree)
main for testing this code 2.14
results
Testing Part 2 2.15
(buildDic, add2File, queryUser, getAWord, display)
main for testing this code 2.15
results
Testing Overall 2.16
(same as testing for part 2)
results
Structure charts 2.17
Data flow diagram 2.18
Program Section 0.1
=======
// 95.204 Assignment # 3 Nov 19/95
#include
#include
#include
#include
#include
#include
#include
#include
#include
// tree structer defination
struct node {
char *value;
struct node *left;
struct node *right;
};
typedef struct node TREE;
void initTree(TREE *dic)
{// init's the tree to NULL
dic->value = NULL;
dic->left = NULL;
dic->right = NULL;
}
void insert(TREE *dic, char *word)
{ // inserts a word into the tree in the correct position
void insertprivate(TREE *dic,TREE *node);
TREE *newPtr=NULL;
newPtr = new TREE;
initTree(newPtr);
if (newPtr != NULL) //checks to see if tree is empty
{ //strcpy(newPtr->value,word); cout<< "here";
if (dic->value == NULL)
dic->value = word;
else
{ newPtr->value = word; //makes a new node
insertprivate(dic,newPtr); //inserts the node into the tree
}
}
else
cout<< "error: not added";
return;
}
void insertprivate(TREE *dic, TREE *node)
{ //does the recursive insert left or right
if (dic->value == NULL)
{
*dic = *node; //cout << "node: " << dic->value <<'\n';
return;
}
else
{ if (stricmp(dic->value,node->value) < 0)
{ //cout << "Adding left";
if (dic->left == NULL) //left insert at leaf
dic->left = node;
else
insertprivate(dic->left,node); //move left and try insert there
}
else { //cout << "Adding right";
if (dic->right == NULL) //right insert at leat
dic->right = node;
else
insertprivate(dic->right,node); //move right and try insert there
}
}
return;
}
int searchTree(const TREE dic, const char *word )
{ //searches the binary search Tree for a word
//cout << "compare: " << dic.value << " and " << word << " = " << stricmp(dic.value,word) << '\n';
if (dic.value == NULL) //checks to see if tree is empty
return 0;
else if (stricmp(dic.value,word) == 0) //checks to see if value if == to the word
return 1;
else
if (stricmp(dic.value,word) < 0)
{ if (dic.left == NULL) //at a leaf and didn't find the word so not in tree
return 0;
else
return searchTree(*(dic.left),word); //checks left subtree
}
else
{ if (dic.right == NULL) //at a leaf and didn't find the word so not in tree
return 0;
else
return searchTree(*(dic.right),word); //checks right subtree
}
}
int findMatchTree(const TREE dic, const char *word)
{ //searchs the tree for a word, when it doesn't find it(as it shouldn't
//it then backs up 4 levels and print's the value
//cout << "matching: " << dic.value << " and " << word << " = " << stricmp(dic.value,word) << '\n';
int counter;
if (dic.value == NULL) //checks for empty tree
{ cout << "No matches found" << '\n';
return 0;
}
// else if ((stricmp(dic.value,word) == 0) && (stricmp(word,dic.value) == 0))
// { //cout << "" << dic.value << " ";
// cout << "" << dic.value << " " << dic.left->value << " " << dic.right->value;
// return 0;
// }
else
if (stricmp(dic.value,word) < 0)
{ if (dic.left == NULL) //at leaf, start to go back up, print the values as you go back up
{ //cout << dic.value << " ";
cout << dic.value << " ";// << dic.left->value << " " << dic.right->value;
return 0;
}
else
{ counter = findMatchTree(*(dic.left),word); //not at leaf, check next level left
if (counter < 3)
cout << dic.value << " ";// << dic.left->value << " " << dic.right->value;
return ++counter;
}
}
else
{ if (dic.right == NULL) //at leaf, start to go back up, print values of tree as you go
{ //cout << dic.value << " ";
cout << dic.value << " ";// << dic.left->value << " " << dic.right->value;
return 0;
}
else
{ counter = findMatchTree(*(dic.right),word); //not at leaf, so check next level
if (counter < 3)
// cout << dic.value << " ";
cout << dic.value << " ";// << dic.left->value << " " << dic.right->value;
return ++counter;
}
}
}
void display(const TREE *dic)
{ //display the tree inorder
if ((dic->left) != NULL) //check to see if leaf
{ //cout << "GOING LEFT";
display(dic->left); //if not go down to next level left
}
cout << dic->value << ' '; //prints the value at current node
if ((dic->right) != NULL) //checls to see if leat
{ //cout << "GOING RIGHT";
display(dic->right); //if not go down to next level right
}
cout << '\n';
return;
}
void buildDic(TREE *dic)
{ //build dictionary from a list of words in a file
char fileName[12];
char aWord[100], *word;
cout << "Enter the name of a file contains a list of words: ";
cin >> fileName;
ifstream in(fileName); //open a file called by fileName
if(!in)
{ cout << "\nCould not open your file\n";
return;
}
cout << "\nWords added: ";
while(in) //repeats until end of file
{ in >> aWord; //reads in word
int length=0; length = strlen(aWord); //cal length of aWord
word = new char[length+1];
strcpy(word,aWord);
cout << word << ", "; //displays word read
insert(dic,word); //inserts into the dictionary tree
}
cout << '\n';
}
// main for Assignment # 3
void main(void)
// Ian Reid
{ // Prototyping functions
void insert(TREE *dic, char *word);
void initTree(TREE *dic);
void display(const TREE *dic);
int searchTree(const TREE dic, const char *word);
int findMatchTree(const TREE dic, const char *word);
void buildDic(TREE *dic);
int queryUser(TREE *dic, char *word);
void getAWord(char aWord[100]);
char fileName[12]; //used to store the filename of the file that is being writen to
TREE dic; //used to store the dictionary as a binary search tree
initTree(&dic); //init's the tree to all NULL
char *word, aWord[100]; //word is dynamical, aWord is a tempary static array
buildDic(&dic); //builds the dictionary from a list of words
cout << "\nDisplay of input dictionary\n";
//display(&dic);
cout << "Enter the name of the text file you want to type: ";
cin >> fileName;
ofstream file(fileName);
if(!file)
{ cout << "Could not open " << fileName << '\n';
exit(1);
}
cout << "\nYou must put type one word per line\n";
cout << "The computer will beep if the word is not in the dictionary\n";
cout << "Type *** as a word to end input\n";
while (stricmp(aWord,"***") != 0) //repeats until *** is inputed
{ getAWord(aWord); //get's a word from the user
if (stricmp(aWord,"***") == 0) //checks to exit condition
break; //exits
int length=0; length = strlen(aWord); //cal length of aWord
if (isalnum(aWord[length-1])) //normal word, no punctuation
{ word = new char[length+1];
strcpy(word,aWord);
word[length] = '\0';
}
else { word = new char[length]; //end's in punctuation
strncpy(word,aWord,length-1);
word[length-1] = '\0';
}
// cout << " You typed: " << word << '\n';
fflush(stdin);
if (searchTree(dic,word) == 0) //searches Tree for word
{// cin.getline(aWord,100);
putchar(007); //beeps
if (queryUser(&dic,word) == 0) //askes the user if word is correct, adds if ok
{ cout << " Matches found: ";
findMatchTree(dic,word); //finds matches in tree of a word
cout << '\n';
}
else file << aWord << ' '; //add's aWord to the output file
}
// cout << word << ' ';
else file << aWord << ' '; //add's aWord to the output file
}
file.close(); //close the file
}
void getAWord(char aWord[100])
{ //get's a word from the user
cin >> aWord;
fflush(stdin);
return;
}
int queryUser(TREE *dic, char *word)
{ //askes the user if a word is ok, if it is adds it to dictionary
char answer;
cout << " Is "<< word <<" correctly spelled(Y,N)?";
cin >> answer;
if ((answer == 'Y') || (answer == 'y'))
{// cout << " ADDING WORD";
insert(dic,word); //adds the word
return 1;
}
else return 0;
}
User Manual Section 1.0
===========
Section 1.1
Program name: spell
Programmer name: Ian Reid, (223779)
address: Carleton University
Statement of Requirements Section 1.2
=-=-=-=-=-=-=-=-=-=-=-=-=
The purpose of this program is to design and implement an
on-line spell checker, ie as the user types a word the program
checks it for spelling. This is done by first processing a text
file of correctly spelled words, making a dictionary. The user
then types a word and the program checks it against the dictionary,
if the word is not found then the program prompts the user. If
the user thinks that the word is correct then the program adds the
word to the dictionary, else the program lists possible words.
Policy on a word Section 1.2
=-=-=-=-=-=-=-=-=
A word is defined by a space followed by at least one
character followed by punctuation and a space, or just a space.
Section 1.3
The program reads in the words from a data file. The data file
contains a list of words, there must be a space or return between each word.
you can have as many words as you like in the file(memory permitting).
For an example of a data file see words.doc, include on disk.
Section 1.4
Program limitations:
Words can be a max of 100 characters long
(words are converted and stored dynamically)
You must press return after each word you type in
When answering yes/no question, only a Y,y will be taken as
confermation
If you enter an invalid prescanned file name, the program
will start with and empty dictionary tree
FileNames can be a max of 12 characters
You need a Pc speaker to hear the sound
files are in same director as program
word can not begin with punctuation
Section 1.5
To run this program in Ibm dos.
1. Goto the director where the program is.
2. Place a copy of your data files in to this director.
3. Run the program.
The Program Reference Manual Section 2.0
============================
Section 2.1
Program name: spell
Programmer name: Ian Reid, (223779)
address: Carleton University
compiler: Turbo C++ for dos v3.1
Statement of Requirements Section 2.2
=-=-=-=-=-=-=-=-=-=-=-=-=
The purpose of this program is to design and implement an
on-line spell checker, ie as the user types a word the program
checks it for spelling. This is done by first processing a text
file of correctly spelled words, making a dictionary. The user
then types a word and the program checks it against the dictionary,
if the word is not found then the program prompts the user. If
the user thinks that the word is correct then the program adds the
word to the dictionary, else the program lists possible words.
Policy on a word Section 2.2
=-=-=-=-=-=-=-=-=
A word is defined by a space followed by at least one
character followed by punctuation and a space, or just a space.
Data Structures Section 2.3
=-=-=-=-=-=-=-=
The dictionary is stored as a binary search tree
to add a word to the dictionary use insert
words cannot be removed
All words are dynamically allocated arrays of chars
Functional Specification Section 2.4
=-=-=-=-=-=-=-=-=-=-=-=-=
>Main Section 2.5
main builds a dictionary, from a text file
it then uses this dictionary to spell check words in real
time that the user enters
Testing
small dictionary, user types a word in dictionary
, user types a word not in dictionary
, user types a word close to a word in
dictionary
, user types a word very different from
the words in dictionary
, user types a long word
, user types a short word
, user types a word with punctuation at
the end
, user types a word with punctuation in
the word
, user types an invalid word
, user types valid word
large dictionary, same tests
empty dictionary, same tests
Peusdo-Code
build dictionary
WHILE there are still words
get word from user
check word
correct?
true add word to text file
false query user
correct?
true add word to text file
add word to dictionary
false list possible matches
END WHILE
>Find a word Section 2.6
Input a word, dictionary
Output a word, correct true or false
checks to see if the word is in the dictionary if it is then
return true, else false.
Testing
normal words
correct
incorrect
words with punctuation
ending with punctuation
punctuation in the middle of a word
short words
long words
no words
Peusdo-Code
if root == a word return 1
if root == NULL return 0
if root is greater than a word
left sub-tree search Tree for a word
else right sub-tree search Tree for a word
>Add to text file Section 2.7
Input a correct word
adds the correct word to the text file
Testing
normal words
short words
long words
adding the first word
adding the last word
Peusdo-Code
open a read/write stream on the file
print out what is currently in the file to the screen
add the word to the end of the file and print to the
screen
>Query user Section 2.8
Input a word
Output true or false
asks the user if the word is correct? returns true or false
Testing
answers correct
answers incorrect
doesn't answer
Peusdo-Code
display word
asked user if word is correct?
if true return true
else false
>Add word to dictionary Section 2.9
Input a word
Output a dictionary search tree
takes a word and adds it to the dictionary search tree
Testing
adding first word
adding last word
adding normal word in the middle
adding short words
adding long words
Peusdo-Code
if root is NULL insert word at root
else check to see if a word is greater than root
if true dictionary right tree insert a word
else dictionary left tree insert a word
>Find matches Section 2.10
Input a word, dictionary search tree
Output a list of possible correct words to the screen
checks the dictionary searching for words that are close to
the input word
Testing
a word in dictionary
a word not in dictionary
a word which is close to a word in the dictionary
a word which isn't close to a word in the dictionary
long words
short words
punctuation words
Pseudo-Code
find the leaf close to a word(a word is close if the
first 3 letters are the same)
if root is not NULL
if root is greater than word
left sub-tree find matches
else right sub-tree find matches
go up three levels and display all children of that tree
if return == 3 then display all children of tree
tree show
else return (return + 1)
>Type word Section 2.11
Input
Output a word
gets a word from the user
Testing
normal words
not a word
punctuation words
long words
short words
Peusdo-Code
WHILE not word
get word from user
end while
return word
>Build Dictionary Section 2.12
Input a filename of a text file of words
Output a binary tree of a dictionary
builds a dictionary up from words in a text file
Testing
small text file
large text file
invalid text file
Peusdo-Code
open the text file
WHILE not eof
read in a word
add the word to the tree
ENDWHILE
close the file
return tree
>Show tree Section 2.13
Input a tree
Output void
Displays the elements in pre-Order of the tree
Testing
build a small tree and display it
build a large tree and display it
build an empty tree and display it
build a bushy tree and display it
build a non-bushy tree and display it
Peusdo-Code
display the root
WHILE left sub-tree is not NULL
display left sub-tree
ENDWHILE
WHILE right sub-tree is not NULL
display right sub-tree
ENDWHILE
Testing Part 1 Section 2.14
=-=-=-=-=-=-=-=
//Testing for insert, initTree, display, searchTree, findMatchTree
void main()
{ // Prototyping functions
void insert(TREE *dic, char *word);
void initTree(TREE *dic);
void display(const TREE *dic);
int searchTree(const TREE dic, const char *word);
int findMatchTree(const TREE dic, const char *word);
void buildDic(TREE *dic);
void add2File(char *word, char *fileName);
int queryUser(TREE *dic, char *word);
void getAWord(char aWord[100]);
TREE dic;
initTree(&dic);
char word[100];
insert(&dic, "me");
insert(&dic, "lunch");
insert(&dic, "food");
insert(&dic, "eat");
insert(&dic, "pipe-dream");
insert(&dic, "zero");
insert(&dic, "eaten");
insert(&dic, "each");
insert(&dic, "understanding");
cout << "\nTree display:\n";
display(&dic);
while (stricmp(word,"***") != 0)
{ cout << "\nEnter word to search for: ";
cin >> word;
cout << "\nresult of search for " << word << " -> " << searchTree(dic,word) << '\n';
cout << "\nFindinf match\n";
findMatchTree(dic,word);
cout << '\n';
}
}
Results
-------
See testing.txt (TEST1.TXT)
Testing Part 2 Section 2.15
=-=-==-=-=-=-=
// testing buildDic, add2File, queryUser, getAWord
void main(void)
// Ian Reid
{ // Prototyping functions
void insert(TREE *dic, char *word);
void initTree(TREE *dic);
void display(const TREE *dic);
int searchTree(const TREE dic, const char *word);
int findMatchTree(const TREE dic, const char *word);
void buildDic(TREE *dic);
void add2File(char *word, char *fileName);
int queryUser(TREE *dic, char *word);
void getAWord(char aWord[100]);
char fileName[12];
TREE dic;
initTree(&dic);
char *word, aWord[100];
buildDic(&dic);
cout << "\nDisplay of input dictionary\n";
display(&dic);
cout << "Enter the name of the text file you want to type: ";
cin >> fileName;
ofstream file(fileName);
if(!file)
{ cout << "Could not open " << fileName << '\n';
exit(1);
}
cout << "\nYou must put type one word perline\n";
cout << "The computer will beep if the word is not in the dictionary\n";
while (stricmp(aWord,"***") != 0)
{ getAWord(aWord);
if (stricmp(aWord,"***") == 0)
break;
int length=0; length = strlen(aWord);
if (isalnum(aWord[length-1])) //normal word, no punctuation
{ word = new char[length+1];
strcpy(word,aWord);
word[length] = '\0';
}
else { word = new char[length]; //end's in punctuation
strncpy(word,aWord,length-1);
word[length-1] = '\0';
}
// cout << " You typed: " << word << '\n';
fflush(stdin);
if (searchTree(dic,word) == 0)
{// cin.getline(aWord,100);
putchar(007); //beeps
if (queryUser(&dic,word) == 0)
{ cout << " Matches found: ";
findMatchTree(dic,word);
cout << '\n';
}
else file << aWord << ' ';
}
// cout << word << ' ';
else file << aWord << ' ';
}
file.close();
}
Results
-------
see results.txt (T1.TXT, T2.TXT, T3.TXT)
and testing.txt (TEST2A.TXT, TEST2B.TXT, TEXT2C.TXT)
Testing Overall Section 2.16
=-=-=-=-=-=-=-=
results
see results.txt (A1.TXT, A2.TXT, A3.TXT)
and testing.txt (TEST3A.TXT, TEST3B.TXT, TEST3C.TXT)
===**=**===
Results.txt
===**=**===
A1.TXT
found he-man she-girl none she-girl help! help help? great
A2.TXT
oh oh well cat good good oh oh well good
A3.TXT
yahoo three! words word smart start the the end! end end.
TOUT.TXT
I am testing text file
T2.TXT
none can found he-man he-man none be
T3.TXT
none none four but can-it can-it! done
TEST.TXT
my what
===**=**===
Testing.txt
===**=**===
TEST1.TXT
=========
Script session started $Revision: 1.1 $
Microsoft(R) MS-DOS(R) Version 6.20
(C)Copyright Microsoft Corp 1981-1993.
C:\204\ASS#3>spellt1
Tree display:
zero understanding pipe-dream me lunch food eaten eat each
Enter word to search for: zero
compare: me and zero = -13
compare: pipe-dream and zero = -10
compare: zero and zero = 0
result of search for zero -> 1
Findinf match
matching: me and zero = -13
matching: pipe-dream and zero = -10
matching: zero and zero = 0
matching: understanding and zero = -5
understanding zero pipe-dream me
Enter word to search for: tekts
compare: me and tekts = -7
compare: pipe-dream and tekts = -4
compare: zero and tekts = 6
compare: understanding and tekts = 1
result of search for tekts -> 0
Findinf match
matching: me and tekts = -7
matching: pipe-dream and tekts = -4
matching: zero and tekts = 6
matching: understanding and tekts = 1
understanding zero pipe-dream me
Enter word to search for: wow!
compare: me and wow! = -10
compare: pipe-dream and wow! = -7
compare: zero and wow! = 3
compare: understanding and wow! = -2
result of search for wow! -> 0
Findinf match
matching: me and wow! = -10
matching: pipe-dream and wow! = -7
matching: zero and wow! = 3
matching: understanding and wow! = -2
understanding zero pipe-dream me
Enter word to search for: pipe-dream
compare: me and pipe-dream = -3
compare: pipe-dream and pipe-dream = 0
result of search for pipe-dream -> 1
Findinf match
matching: me and pipe-dream = -3
matching: pipe-dream and pipe-dream = 0
pipe-dream me
Enter word to search for: pop_can
compare: me and pop_can = -3
compare: pipe-dream and pop_can = -6
compare: zero and pop_can = 10
compare: understanding and pop_can = 5
result of search for pop_can -> 0
Findinf match
matching: me and pop_can = -3
matching: pipe-dream and pop_can = -6
matching: zero and pop_can = 10
matching: understanding and pop_can = 5
understanding zero pipe-dream me
Enter word to search for: me
compare: me and me = 0
result of search for me -> 1
Findinf match
matching: me and me = 0
matching: lunch and me = -1
lunch me
Enter word to search for: a
compare: me and a = 12
compare: lunch and a = 11
compare: food and a = 5
compare: eat and a = 4
compare: each and a = 4
result of search for a -> 0
Findinf match
matching: me and a = 12
matching: lunch and a = 11
matching: food and a = 5
matching: eat and a = 4
matching: each and a = 4
each eat food lunch
Enter word to search for: understanding
compare: me and understanding = -8
compare: pipe-dream and understanding = -5
compare: zero and understanding = 5
compare: understanding and understanding = 0
result of search for understanding -> 1
Findinf match
matching: me and understanding = -8
matching: pipe-dream and understanding = -5
matching: zero and understanding = 5
matching: understanding and understanding = 0
understanding zero pipe-dream me
Enter word to search for: understandable
compare: me and understandable = -8
compare: pipe-dream and understandable = -5
compare: zero and understandable = 5
compare: understanding and understandable = 8
result of search for understandable -> 0
Findinf match
matching: me and understandable = -8
matching: pipe-dream and understandable = -5
matching: zero and understandable = 5
matching: understanding and understandable = 8
understanding zero pipe-dream me
Enter word to search for:
" "
compare: me and " = 43
compare: lunch and " = 42
compare: food and " = 36
compare: eat and " = 35
compare: each and " = 35
result of search for " -> 0
Findinf match
matching: me and " = 43
matching: lunch and " = 42
matching: food and " = 36
matching: eat and " = 35
matching: each and " = 35
each eat food lunch
Enter word to search for: compare: me and " = 43
compare: lunch and " = 42
compare: food and " = 36
compare: eat and " = 35
compare: each and " = 35
result of search for " -> 0
Findinf match
matching: me and " = 43
matching: lunch and " = 42
matching: food and " = 36
matching: eat and " = 35
matching: each and " = 35
each eat food lunch
Enter word to search for: ''
compare: me and '' = 38
compare: lunch and '' = 37
compare: food and '' = 31
compare: eat and '' = 30
compare: each and '' = 30
result of search for '' -> 0
Findinf match
matching: me and '' = 38
matching: lunch and '' = 37
matching: food and '' = 31
matching: eat and '' = 30
matching: each and '' = 30
each eat food lunch
Enter word to search for: zpelling
compare: me and zpelling = -13
compare: pipe-dream and zpelling = -10
compare: zero and zpelling = -11
result of search for zpelling -> 0
Findinf match
matching: me and zpelling = -13
matching: pipe-dream and zpelling = -10
matching: zero and zpelling = -11
zero pipe-dream me
Enter word to search for: spelling
compare: me and spelling = -6
compare: pipe-dream and spelling = -3
compare: zero and spelling = 7
compare: understanding and spelling = 2
result of search for spelling -> 0
Findinf match
matching: me and spelling = -6
matching: pipe-dream and spelling = -3
matching: zero and spelling = 7
matching: understanding and spelling = 2
understanding zero pipe-dream me
Enter word to search for: ***
compare: me and *** = 35
compare: lunch and *** = 34
compare: food and *** = 28
compare: eat and *** = 27
compare: each and *** = 27
result of search for *** -> 0
Findinf match
matching: me and *** = 35
matching: lunch and *** = 34
matching: food and *** = 28
matching: eat and *** = 27
matching: each and *** = 27
each eat food lunch
C:\204\ASS#3>exit
Script completed Fri Dec 01 04:39:59 1995
TEST2A.TXT
==========
Script session started $Revision: 1.1 $
Microsoft(R) MS-DOS(R) Version 6.20
(C)Copyright Microsoft Corp 1981-1993.
[1;31m 4:40:34.77 C:\VWIN\204\ASS#3>[1;36mspellt2
Enter the name of a file contains a list of words: text.txt
Words added: my, what, ,
Display of input dictionary
what
my
Enter the name of the text file you want to type: tout.txt
You must put type one word perline
The computer will beep if the word is not in the dictionary
I
Is I correctly spelled(Y,N)?y
am
Is am correctly spelled(Y,N)?n
Matches found: I my
am
Is am correctly spelled(Y,N)?y
testing
Is testing correctly spelled(Y,N)?y
small
Is small correctly spelled(Y,N)?n
Matches found: testing what my
text
Is text correctly spelled(Y,N)?y
file
Is file correctly spelled(Y,N)?y
***
[1;31m 4:43:21.03 C:\VWIN\204\ASS#3>[1;36mexit
Script completed Fri Dec 01 04:43:23 1995
TEST2B.TXT
==========
Script session started $Revision: 1.1 $
Microsoft(R) MS-DOS(R) Version 6.20
(C)Copyright Microsoft Corp 1981-1993.
[1;31m 4:46:29.09 C:\VWIN\204\ASS#3>spellt2
Enter the name of a file contains a list of words: none
Could not open your file
Display of input dictionary
Enter the name of the text file you want to type: t2.txt
You must put type one word perline
The computer will beep if the word is not in the dictionary
none
Is none correctly spelled(Y,N)?n
Matches found: No matches found
none
Is none correctly spelled(Y,N)?y
help
Is help correctly spelled(Y,N)?n
Matches found: none
can
Is can correctly spelled(Y,N)?y
be
Is be correctly spelled(Y,N)?n
Matches found: can none
found
Is found correctly spelled(Y,N)?y
he-man
Is he-man correctly spelled(Y,N)?y
he-man
none
help
Is help correctly spelled(Y,N)?n
Matches found: he-man found can none
be
Is be correctly spelled(Y,N)?y
***
[1;31m 4:47:55.27 C:\VWIN\204\ASS#3>[1;36mexit
Script completed Fri Dec 01 04:47:57 1995
TEST2C.TXT
==========
Script session started $Revision: 1.1 $
Microsoft(R) MS-DOS(R) Version 6.20
(C)Copyright Microsoft Corp 1981-1993.
[1;31m 4:48:59.92 C:\VWIN\204\ASS#3>[1;36mspellt2
Enter the name of a file contains a list of words: words.doc
Words added: most, my, numbers, of, only, over, people, prove, right, same, start, you, all, and, are, before, but, can, could, four, get, go, help, stop, straight, taking, that, think, three, to, well, what, words, world, would, I, if, is, it, jacket, jus
Display of input dictionary
you would
world
words
what
well very
to
three
think
that
taking sucker
straight
stop
start smart
same
right
prove
people
over
only
of
numbers
my
most me
light
let
labelling
just
jacket
it
is
if
I
help
go
get
four
could computer
can
but
before aren't
are
and
all
Enter the name of the text file you want to type: t3.txt
You must put type one word perline
The computer will beep if the word is not in the dictionary
none
Is none correctly spelled(Y,N)?n
Matches found: numbers my most
none
Is none correctly spelled(Y,N)?y
none
be
Is be correctly spelled(Y,N)?k
Matches found: aren't before are and
line over flow
Is line correctly spelled(Y,N)? Matches found: me light let labelling
Is ver correctly spelled(Y,N)? Matches found: very well to three
Is low correctly spelled(Y,N)?n
Matches found: me light let labelling
understading
Is understading correctly spelled(Y,N)?n
Matches found: very well to three
evil-man
Is evil-man correctly spelled(Y,N)?n
Matches found: four could can but
four
but
can-it
Is can-it correctly spelled(Y,N)?y
can-it!
lunch-break.
Is lunch-break correctly spelled(Y,N)?n
Matches found: me light let labelling
label
Is label correctly spelled(Y,N)?n
Matches found: labelling just jacket it
done
Is done correctly spelled(Y,N)?y
***
[1;31m 4:51:21.46 C:\VWIN\204\ASS#3>[1;36mexit
Script completed Fri Dec 01 04:51:22 1995
TEST3A.TXT
==========
Script session started $Revision: 1.1 $
Microsoft(R) MS-DOS(R) Version 6.20
(C)Copyright Microsoft Corp 1981-1993.
[1;31m 4:55:20.39 C:\VWIN\204\ASS#3>[1;36mspell
Enter the name of a file contains a list of words: t2.txt
Words added: none, can, found, he-man, he-man, none, be, ,
Display of input dictionary
Enter the name of the text file you want to type: a1.txt
You must put type one word per line
The computer will beep if the word is not in the dictionary
Type *** as a word to end input
goody
Is goody correctly spelled(Y,N)?n
Matches found: he-man he-man found can
found
n0ne
Is n0ne correctly spelled(Y,N)?n
Matches found: none he-man found can
he-man
he-men
Is he-men correctly spelled(Y,N)?n
Matches found: none he-man found can
she-girl
Is she-girl correctly spelled(Y,N)?y
she
Is she correctly spelled(Y,N)?n
Matches found: she-girl none
none
goody
Is goody correctly spelled(Y,N)?n
Matches found: he-man he-man found can
she-girl
help!
Is help correctly spelled(Y,N)?n
Matches found: none he-man found can
help!
Is help correctly spelled(Y,N)?y
help
help?
great
Is great correctly spelled(Y,N)?y
work
Is work correctly spelled(Y,N)?n
Matches found: she-girl none
***
[1;31m 4:57:17.54 C:\VWIN\204\ASS#3>[1;36mexit
Script completed Fri Dec 01 04:57:19 1995
TEST3B.TXT
==========
Script session started $Revision: 1.1 $
Microsoft(R) MS-DOS(R) Version 6.20
(C)Copyright Microsoft Corp 1981-1993.
[1;31m 4:58:09.28 C:\VWIN\204\ASS#3>[1;36mspell
Enter the name of a file contains a list of words: none
Words added: ,
Display of input dictionary
Enter the name of the text file you want to type: a2.txt
You must put type one word per line
The computer will beep if the word is not in the dictionary
Type *** as a word to end input
goody
Is goody correctly spelled(Y,N)?n
Matches found:
oh well
Is oh correctly spelled(Y,N)? Matches found:
Is ell correctly spelled(Y,N)?n
Matches found:
oh
Is oh correctly spelled(Y,N)?y
oh well
Is well correctly spelled(Y,N)?y
a
Is a correctly spelled(Y,N)?n
Matches found: oh
z
Is z correctly spelled(Y,N)?n
Matches found: well oh
cat
Is cat correctly spelled(Y,N)?y
dog
Is dog correctly spelled(Y,N)?fish
Matches found: cat oh
Is ish correctly spelled(Y,N)?n
Matches found: cat oh
good
Is good correctly spelled(Y,N)?y
good
oh
oh well good
a
Is a correctly spelled(Y,N)?n
Matches found: cat oh
z
Is z correctly spelled(Y,N)?n
Matches found: well oh
***
[1;31m 4:59:55.12 C:\VWIN\204\ASS#3>[1;36mexit
Script completed Fri Dec 01 04:59:57 1995
TEST3C.TXT
==========
Script session started $Revision: 1.1 $
Microsoft(R) MS-DOS(R) Version 6.20
(C)Copyright Microsoft Corp 1981-1993.
[1;31m 5:00:41.43 C:\VWIN\204\ASS#3>[1;36mspell
Enter the name of a file contains a list of words: words.doc
Words added: most, my, numbers, of, only, over, people, prove, right, same, start, you, all, and, are, before, but, can, could, four, get, go, help, stop, straight, taking, that, think, three, to, well, what, words, world, would, I, if, is, it, jacket, just
Display of input dictionary
Enter the name of the text file you want to type: a3.txt
You must put type one word per line
The computer will beep if the word is not in the dictionary
Type *** as a word to end input
yahoo
Is yahoo correctly spelled(Y,N)?n
Matches found: would world words what
yahoo
Is yahoo correctly spelled(Y,N)?y
three!
going
Is going correctly spelled(Y,N)?n
Matches found: help go get four
words
word
Is word correctly spelled(Y,N)?y
w0rd
Is w0rd correctly spelled(Y,N)?n
Matches found: very well to three
smart
sm-rt
Is sm-rt correctly spelled(Y,N)?n
Matches found: smart start same right
start
the end!
Is the correctly spelled(Y,N)? Matches found: think that taking straight
Is nd correctly spelled(Y,N)?n
Matches found: numbers my most
the
Is the correctly spelled(Y,N)?y
the
end!
Is end correctly spelled(Y,N)?y
end
end.
***
[1;31m 5:02:38.25 C:\VWIN\204\ASS#3>[1;36mexit
Script completed Fri Dec 01 05:02:39 1995 Text file Source (historic): geocities.com/x_xet/data
geocities.com/x_xet(to report bad content: archivehelp @ gmail)
|
|
|
|
|