-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMorseCodeTester.cpp
More file actions
50 lines (50 loc) · 1.58 KB
/
MorseCodeTester.cpp
File metadata and controls
50 lines (50 loc) · 1.58 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
//// This has been commented out so that main.cpp will run instead.
//// FOR TESTING ONLY--DO NOT TURN IN
//// Alfred Ledgin
//// 12/4/2015
//// CS 303
//// Project 3
//
//#include <iostream>
//#include "MorseCode.h"
//#include "MorseSystem.h"
//#include <fstream>
//#include <vector>
//using namespace std;
//
//
//int main()
//{
// ifstream file;
// file.open("morse.txt");
// MorseCode testCode(file);
// file.close();
// cout << testCode.showCodeTree() << endl;
// cout << "***" << endl;
// cout << testCode.decodeLetter("_..") << endl;
// cout << "***" << endl;
// cout << testCode.encodeLetter('C') << endl;
// cout << "***" << endl;
// vector<string> decodeTestVec;
// decodeTestVec = { "_..", "__." };
// cout << testCode.decodeWord(decodeTestVec) << endl;
// cout << "***" << endl;
// cout << testCode.encodeWord("ac") << endl;
// cout << "***" << endl;
// vector<string> decodeTestVec2 = testCode.parse("_.. __. _.. __.");
// cout << testCode.decodeWord(decodeTestVec2) << endl;
// cout << "***" << endl;
// cout << testCode.interpret("_.. __. _.. __. _.. __.") << endl;
// cout << "***" << endl;
// MorseSystem theSystem;
// file.open("morse.txt");
// theSystem.setInput(file);
// file.close();
// cout << theSystem.decodeWord("_.. __. _.. __. _.. __. _.. __.") << endl;
// system("pause");
// return 0;
//}
//// Reference for tested input:
// // Kuhail, Mohammad. "Project 3." Project assignment sheet,
// // CS 303 course materials, University of Missouri-Kansas City,
// // Fall 2015. PDF file. Pages 4-5.