Question
Please help me fix this error I get from the following code: CourseGradebook.h #ifndef COURSEGRADEBOOK_H #define COURSEGRADEBOOK_H #include #include Gradebook.h class CourseGradebook : public Gradebook
Please help me fix this error I get from the following code:
CourseGradebook.h
#ifndef COURSEGRADEBOOK_H #define COURSEGRADEBOOK_H
#include
class CourseGradebook : public Gradebook { protected: std::unordered_map
public: virtual ~CourseGradebook() {}
std::unordered_map
double GetScore(std::string assignmentName, int studentID) override { if (gradebookData.count(assignmentName) == 0 || gradebookData[assignmentName].count(studentID) == 0) { return NAN; } return gradebookData[assignmentName][studentID]; }
std::vector
std::vector
std::unordered_map
void SetScore(std::string assignmentName, int studentID, double score) override { gradebookData[assignmentName][studentID] = score; } };
#endif
Error
In file included from main.cpp:6: CourseGradebook.h: In member function virtual std::unordered_map
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started