Keep getting error code on self organizing list assignment. Need help figuring out how to fix the error.
Keep getting error code on self organizing list assignment. Need help figuring out how to fix the error.
Database System Concepts
7th Edition
ISBN:9780078022159
Author:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Chapter1: Introduction
Section: Chapter Questions
Problem 1PE
Related questions
Question
Keep getting error code on self organizing list assignment. Need help figuring out how to fix the error.
![File
Edit
View
Git
Project
Build
Debug
Test
Analyze
Tools
Extensions
Window
Help
Search (Ctrl+Q)
OrganizingList
KD
Debug
• Local Windows Debugger D
口员习闪=
A Live Share
x64
RC
Test.txt 7
Source.cpp + x Count1.h
MoveToFront.h
list.h
SelfOrderedListADT.h
llist.h
book.h
link.h
OrganizingList
(Global Scope)
B//<Self Organizing List> --
//CSIS 215-<D©1>
E#include <stdio.h>
organize lists using different heuristics
2
#include <fstream>
6
#include "Countl.h"
7
#include "MoveToFront.h"
#include "TransposeList.h"
#include <string>
8
10
11
Bint main() {
cout << "Kenyetta Douglas Assignment 4" « endl;
char charIns[] = { 'A', 'B', 'C', 'D', 'E', 'F', 'G', 'H' };
int charInsLength = sizeof(charIns) / sizeof(charIns[0]);
12
13
14
15
char charFinds[] = { 'F', 'D', 'F', 'G', 'E', 'G', 'F', 'A', 'D', 'F', 'G', 'E', 'H', 'I' };
int charFindsLength = sizeof(CcharFinds) / sizeof(charFinds[0]);
16
17
18
19
// Count heuristic
printf("COUNT HEURISTIC: Chars\n");
20
21
22
23
Count1<char>* countList = new Countl<char>();
24
for (int i = 0; i < charInsLength; ++i) {
countlist->add(charIns[i]D;
25
26
27
100 %
e (local variable) char charlns[8]
Search Online
Error List
Entire Solution
X 15 Errors
O Warnings
O 0 of 60 Messages 7
Build + IntelliSense
Code
Description -
Project
F
* C2259
"Count1<char>': cannot instantiate abstract class
OrganizingList
X C2259
"Count1<char>: cannot instantiate abstract class
OrganizingList
X C2259
* C2259
"Count1<std:string>': cannot instantiate abstract class
"Count1<std:string>': cannot instantiate abstract class
OrganizingList
OrganizingList
Source.cpp
81
X C2259
'MoveToFront<char>': cannot instantiate abstract class
OrganizingList
Source.cpp
40
Transposelist' instantiations Error List Output
O Window auto hidden: Properties
T Add to Source Control
Select Repository -
7:43 PM
a
12/17/2021
Notifications Solution Explorer Git Changes Properties
Server Explorer Toolbox](/v2/_next/image?url=https%3A%2F%2Fcontent.bartleby.com%2Fqna-images%2Fquestion%2F831ac227-9119-4784-af0d-25277b612a50%2Fad076802-dda5-461d-86cd-4660566ab9ed%2Fyyos369_processed.png&w=3840&q=75)
Transcribed Image Text:File
Edit
View
Git
Project
Build
Debug
Test
Analyze
Tools
Extensions
Window
Help
Search (Ctrl+Q)
OrganizingList
KD
Debug
• Local Windows Debugger D
口员习闪=
A Live Share
x64
RC
Test.txt 7
Source.cpp + x Count1.h
MoveToFront.h
list.h
SelfOrderedListADT.h
llist.h
book.h
link.h
OrganizingList
(Global Scope)
B//<Self Organizing List> --
//CSIS 215-<D©1>
E#include <stdio.h>
organize lists using different heuristics
2
#include <fstream>
6
#include "Countl.h"
7
#include "MoveToFront.h"
#include "TransposeList.h"
#include <string>
8
10
11
Bint main() {
cout << "Kenyetta Douglas Assignment 4" « endl;
char charIns[] = { 'A', 'B', 'C', 'D', 'E', 'F', 'G', 'H' };
int charInsLength = sizeof(charIns) / sizeof(charIns[0]);
12
13
14
15
char charFinds[] = { 'F', 'D', 'F', 'G', 'E', 'G', 'F', 'A', 'D', 'F', 'G', 'E', 'H', 'I' };
int charFindsLength = sizeof(CcharFinds) / sizeof(charFinds[0]);
16
17
18
19
// Count heuristic
printf("COUNT HEURISTIC: Chars\n");
20
21
22
23
Count1<char>* countList = new Countl<char>();
24
for (int i = 0; i < charInsLength; ++i) {
countlist->add(charIns[i]D;
25
26
27
100 %
e (local variable) char charlns[8]
Search Online
Error List
Entire Solution
X 15 Errors
O Warnings
O 0 of 60 Messages 7
Build + IntelliSense
Code
Description -
Project
F
* C2259
"Count1<char>': cannot instantiate abstract class
OrganizingList
X C2259
"Count1<char>: cannot instantiate abstract class
OrganizingList
X C2259
* C2259
"Count1<std:string>': cannot instantiate abstract class
"Count1<std:string>': cannot instantiate abstract class
OrganizingList
OrganizingList
Source.cpp
81
X C2259
'MoveToFront<char>': cannot instantiate abstract class
OrganizingList
Source.cpp
40
Transposelist' instantiations Error List Output
O Window auto hidden: Properties
T Add to Source Control
Select Repository -
7:43 PM
a
12/17/2021
Notifications Solution Explorer Git Changes Properties
Server Explorer Toolbox
![File
Edit
View
Git
Project
Build
Debug
Test
Analyze
Tools
Extensions
Window
Help
Search (Ctrl+Q)
OrganizingList
KD
Debug
• Local Windows Debugger D
口员习闪=
A Live Share
x64
RC
Test.txt 4
Source.cpp + x Count1.h
MoveToFront.h
list.h
SelfOrderedListADT.h
llist.h
book.h
link.h
* OrganizingList
(Global Scope)
O main)
}
for (int i = 0; i < charFindsLength; ++i) {
moveToFront->find(charFinds[i]);
}
44
45
46
47
48
printf("Size of list: %d\n", moveToFront->size());
printf("Number of compares: %d\n", moveToFront->getCompares());
moveToFront->printlist();
printf("\n");
49
50
51
52
53
// Transpose heuristic
printf("Transpose HEURISTIC: Chars\n");
54
55
56
57
TransposeList<char>* transposeList = new Transposelist<char>();
58
for (int i = 0; i < charInsLength; ++i) {
transposelist->add(charIns[i]);
}
for (int i = 0; i < charFindsLength; ++i) {
transposelist->find(charFinds[i]);
}
59
60
61
62
63
64
65
printf("Size of list: %d\n", transposeList->size());
printf("Number of compares: %d\n", transposeList->getCompares());
transposelist->printlist();
printf("\n");
66
67
68
69
100 %
Ln: 57
Ch: 43
Col: 46
TABS
CRLF
Error List
Entire Solution
X 15 Errors
O Warnings
O 0 of 60 Messages 7
Build + IntelliSense
Code
Description -
Project
F
abc E0322
object of abstract class type "Count1<char>" is not allowed:
OrganizingList
Source.cpp
23
D abc E0322
object of abstract class type "Count1<std:string>" is not allowed:
OrganizingList
Source.cpp
81
D abc E0322
object of abstract class type "MoveToFront<char>" is not allowed:
OrganizingList
Source.cpp
40
D abc E0322
object of abstract class type "TransposeList<char>" is not allowed:
OrganizingList
Source.cpp
57
D abc E0322
object of abstract class type "Transposelist<std:string>" is not allowed:
OrganizingList
Source.cpp
98
"TransposelList' instantiations Error List Output
O Ready
T Add to Source Control
Select Repository -
7:44 PM
a
12/17/2021
Notifications Solution Explorer Git Changes Properties
Server Explorer Toolbox](/v2/_next/image?url=https%3A%2F%2Fcontent.bartleby.com%2Fqna-images%2Fquestion%2F831ac227-9119-4784-af0d-25277b612a50%2Fad076802-dda5-461d-86cd-4660566ab9ed%2F398dbh1_processed.png&w=3840&q=75)
Transcribed Image Text:File
Edit
View
Git
Project
Build
Debug
Test
Analyze
Tools
Extensions
Window
Help
Search (Ctrl+Q)
OrganizingList
KD
Debug
• Local Windows Debugger D
口员习闪=
A Live Share
x64
RC
Test.txt 4
Source.cpp + x Count1.h
MoveToFront.h
list.h
SelfOrderedListADT.h
llist.h
book.h
link.h
* OrganizingList
(Global Scope)
O main)
}
for (int i = 0; i < charFindsLength; ++i) {
moveToFront->find(charFinds[i]);
}
44
45
46
47
48
printf("Size of list: %d\n", moveToFront->size());
printf("Number of compares: %d\n", moveToFront->getCompares());
moveToFront->printlist();
printf("\n");
49
50
51
52
53
// Transpose heuristic
printf("Transpose HEURISTIC: Chars\n");
54
55
56
57
TransposeList<char>* transposeList = new Transposelist<char>();
58
for (int i = 0; i < charInsLength; ++i) {
transposelist->add(charIns[i]);
}
for (int i = 0; i < charFindsLength; ++i) {
transposelist->find(charFinds[i]);
}
59
60
61
62
63
64
65
printf("Size of list: %d\n", transposeList->size());
printf("Number of compares: %d\n", transposeList->getCompares());
transposelist->printlist();
printf("\n");
66
67
68
69
100 %
Ln: 57
Ch: 43
Col: 46
TABS
CRLF
Error List
Entire Solution
X 15 Errors
O Warnings
O 0 of 60 Messages 7
Build + IntelliSense
Code
Description -
Project
F
abc E0322
object of abstract class type "Count1<char>" is not allowed:
OrganizingList
Source.cpp
23
D abc E0322
object of abstract class type "Count1<std:string>" is not allowed:
OrganizingList
Source.cpp
81
D abc E0322
object of abstract class type "MoveToFront<char>" is not allowed:
OrganizingList
Source.cpp
40
D abc E0322
object of abstract class type "TransposeList<char>" is not allowed:
OrganizingList
Source.cpp
57
D abc E0322
object of abstract class type "Transposelist<std:string>" is not allowed:
OrganizingList
Source.cpp
98
"TransposelList' instantiations Error List Output
O Ready
T Add to Source Control
Select Repository -
7:44 PM
a
12/17/2021
Notifications Solution Explorer Git Changes Properties
Server Explorer Toolbox
Expert Solution

This question has been solved!
Explore an expertly crafted, step-by-step solution for a thorough understanding of key concepts.
Step by step
Solved in 2 steps

Knowledge Booster
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.Recommended textbooks for you

Database System Concepts
Computer Science
ISBN:
9780078022159
Author:
Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:
McGraw-Hill Education

Starting Out with Python (4th Edition)
Computer Science
ISBN:
9780134444321
Author:
Tony Gaddis
Publisher:
PEARSON

Digital Fundamentals (11th Edition)
Computer Science
ISBN:
9780132737968
Author:
Thomas L. Floyd
Publisher:
PEARSON

Database System Concepts
Computer Science
ISBN:
9780078022159
Author:
Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:
McGraw-Hill Education

Starting Out with Python (4th Edition)
Computer Science
ISBN:
9780134444321
Author:
Tony Gaddis
Publisher:
PEARSON

Digital Fundamentals (11th Edition)
Computer Science
ISBN:
9780132737968
Author:
Thomas L. Floyd
Publisher:
PEARSON

C How to Program (8th Edition)
Computer Science
ISBN:
9780133976892
Author:
Paul J. Deitel, Harvey Deitel
Publisher:
PEARSON

Database Systems: Design, Implementation, & Manag…
Computer Science
ISBN:
9781337627900
Author:
Carlos Coronel, Steven Morris
Publisher:
Cengage Learning

Programmable Logic Controllers
Computer Science
ISBN:
9780073373843
Author:
Frank D. Petruzella
Publisher:
McGraw-Hill Education