Project Description

(1) Collect to imagine systematize composition in C++

(2) Imagine an adorn of intents in C++

(3) Search and transact operations on the adorn of intents

Project Description:

The input csv polish for this contrivance consists of rows of grounds that deals delay COVID-19 events and deaths per day for each county in completion particularize in the United States. Hither is an stance,

date,county,state,fips,cases,deaths

2020-01-21,Snohomish,Washington,53061,1,0

2020-01-22,Snohomish,Washington,53061,1,0

2020-01-23,Snohomish,Washington,53061,1,0

For the purposes of this contrivance, we allure pretend that the subjoined are char* grounds stamps: time, county, and particularize. FIPS (sole identifier for each county) parallel delay events and deaths are int grounds stamps. Please melody the comma delimiter in each row. You scarcity ­­­to carefully decipher each scene experienced that you allure entertain a comma.

You allure use redirected input (over behind) to decipher an input txt polish that contains the subjoined:

counts  //enumerate of grounds entries in the csv polish

Filename.csv  //this is the polish that contains the covid-19 grounds

Command  //details of what constitutes a enjoin is fond underneath

Command

Command

….

Your C++ program allure decipher the counts esteem on the foremost thinterpret of the txt polish, which represents the enumerate of grounds entries in the csv polish. (Note - the foremost thinterpret of the csv polish contains pictorial capricious scenes, so thither allure be a completion of [enumerate of grounds entries + 1] threads in the csv polish). Then, on the prevent thread, it allure decipher the Filename.csv and unreserved the polish for deciphering (over on how to do this in C++). Behind you unreserved the polish, you allure decipher the grounds from each row of the csv polish and imagine a COVID19 intent. The COVID19 systematize is fond underneath. You scarcity to utensil all of the expedient methods.

systematize COVID19 {

protected:

char* time;

char* county;

char* particularize;

int fips;

int events;

int deaths;

public:

COVID19 (); //default constructor

COVID19 (char* da, char* co, char* s, int f, 

 int ca, int de); //initializer

vault ();

//transcribe all advanceors and other methods as expedient

};

After your transcribe the over systematize you allure transcribe the subjoined systematize:

systematize COVID19DataSet {

protected:

COVID19* allData;

int count; //enumerate of COVID19 intents in allData

int bigness; //maximum bigness of adorn

public:

COVID19DataSet (); //default constructor

COVID19DataSet (int initSize);

void vault ();

void addRow (COVID19& oneData);

int experienceTotalCasesByCounty (char* county, char* particularize); 

int experienceTotalDeathsByCounty (char* county, char* particularize);

int experienceTotalCasesByState (char* particularize);

int experienceTotalDeathsByState (char* particularize); 

int experienceTotalCasesBySateWithDateRange (char* particularize,

char* rouseDate, char* endDate);

int experienceTotalDeathsBySateWithDateRange (char* particularize,

char* rouseDate, char* endDate);

~COVID19(); //destructor

//other methods as estimate important

};

The composition of the deep program allure be triton affect this:

#include <iostream>

using spectryinterspace std;

// Transcribe all the systematizees hither

int deep () {

int counts; // enumerate of history in Filename.CSV

int enjoin;

COVID19 oneRow;

//decipher the polishname, for stance, Filename.csv

//unreserved the Filename.csv using funreserved (google it for C++ to experience out)

//pretend that you designated this polish as myFile

//decipher the foremost integer in the polish that contains the enumerate of rows

//call this enumerate counts

COVID19DataSet* myData = new COVID19DataSet (counts);

for (int i=0; i < counts; i++) {

//decipher the esteems in each row

//use setters to set the scenes in oneRow

(*myData).addRow (oneRow);

} //end for loop

period (!cin.eof()) {

cin >> enjoin;

switch (command) {

event 1: {

//decipher the tranquillity of the row

(*myData).findTotalCasesByCounty (county, particularize);

break;

 }

event 2: {

 //do what is scarcityed for enjoin 2

 break;

 }

event 3: {

 //do what is scarcityed for enjoin 3

 break;

 }

event 4: {

 //do what is scarcityed for enjoin 4

 break;

 }

event 5: {

 //do what is scarcityed for enjoin 5

 break;

 }

event 6: {

 //do what is scarcityed for enjoin 6

 break;

 }

default: cout << “Wrong enjoin\n”;

} //end switch

} //end period

delete myData;

return 0;

}

Input Structure:

The input txt polish allure entertain the subjoined composition – I entertain annotated hither for reason and these annotations allure not be in the developed input polish. Behind the foremost two threads, the retaining threads in the input txt polish contains enjoins (one enjoin per thread), whither thither can be up to 6 opposed enjoins in any appoint delay any enumerate of entries. The enjoin is indicated by an integer [1 to 6] and can be fix at the opening of each thread.

counts // Enumerate of grounds entries in the csv polish 

Covid-19-Data-csv  // Spectry of the input polish that contains the developed Covid-19 grounds by county and particularize

1 Cleveland, Oklahoma //enjoin 1 hither is for experienceTotalCasesByCounty

1 Walla Walla, Washington 

1 San Francisco, California

1 Tulsa, Oklahoma

2 Oklahoma, Oklahoma //enjoin 2 hither is for experienceTotalDeathsByCounty

2 Miami, Ohio

2 Miami, Oklahoma

3 Oklahoma //enjoin 3 hither is for experienceTotalCasesByState

3 North Carolina

4 New York //enjoin 4 hither is for experienceTotalDeathsByState

4 Arkansas

5 Oklahoma 2020-03-19 2020-06-06 //5 hither is for experienceTotalCasesBySateWithDateRange

6 New York 2020-04-01 2020-06-06 //6 hither is for experienceTotalDeathsBySateWithDateRange

Redirected Input

Redirected input provides you a way to despatch a polish to the model input of a program delayout typing it using the keyboard. To use redirected input in Visual Studio environment, flourish these steps: Behind you entertain unreserveded or imagined a new contrivance, on the menu go to contrivance, contrivance properties, open outline properties until you see Debugging, on the straight you allure see a set of options, and in the enjoin arguments stamp “< input polishname”. The < presage is for redirected input and the input polishname is the spectry of the input polish (including the method if not in the agoing directory). A humble program that deciphers mark by mark until it reaches end-of-polish can be fix underneath.

#include <iostream>

using spectryinterspace std;

//The mark for end-of-thinterpret is ‘\n’ and you can assimilate c underneath delay this 

//mark to cohibit if end-of-thinterpret is reached.

int deep () {

char c;

cin.get(c);

period (!cin.eof()) {

cout << c;

cin.get(c);

}

return 0;

}

C String

A string in the C Programming Language is an adorn of marks ends delay ‘\0’ (NULL) mark. The NULL mark denotes the end of the C string. For stance, you can state a C string affect this:

char aCString[9];

Then you allure be cogent to garner up to 8 marks in this string. You can use cout to stereofashion out the string and the marks garnerd in a C string allure be vaulted one by one until ‘\0’ is reached. Hither are some stances:

0

1

2

3

4

5

6

7

8

cout result

Length

u

s

e

r

n

a

m

e

\0

username

8

n

a

m

e

\0

name

4

n

a

m

e

\0

1

2

3

4

name

4

\0

(nothing)

0

Similarly, you can use a for loop to mention the diffusiveness of a string (NULL is NOT included). We appearance this in the subjoined and to-boot appearance how you can dynamically imagine a string using a pointer

char aCString[] = "This is a C String."; // you don’t scarcity to provide

// the bigness of the adorn

// if the resigned is provided

char* anotherCString; // a pointer to an adorn of

// marks

unsigned int diffusiveness = 0;

while( aCString[length] != '\0')

{

length++;

}

// the diffusiveness of the string is now known

anotherCString = new char[length+1]; // scarcity interinterspace for NULL mark

// observation the string

for( int i=0; i< diffusiveness+1; i++)

 anotherCString[i] = aCString[i];

 cout << aCString << endl; // stereofashion out the two strings

cout << anotherCSring << endl;

delete [] anotherCString; // indemnify the reminiscence behind use

You can cohibit http://www.cs.bu.edu/teaching/cpp/string/array-vs-ptr/, other onthinterpret sources or quotationbooks to collect over encircling this.

Output Structure

Stay tuned for the fit format in which the output of your program should be formatted. For now, it is recommended to rouse agoing on deciphering in the input polishs, storing the grounds, and advanceing the grounds installed on the fond enjoins.

Constraints

1. In this contrivance, the solely header you allure use is #include <iostream> and using spectryinterspace std.

2. None of the contrivances is a assembly contrivance. Consulting delay other members of this systematize our seeking coding solutions from other sources including the web on programming contrivances is strictly not allowed and plagiarism account allure be imposed on students who do not flourish this.

Rules for Gradescope (Project 1):

1. Students entertain to advance GradeScope through Canvas using the GradeScope tab on the left, or by clicking on the Contrivance 1 enactment meekness trifle.

2. Students should upload their program as a barely cpp polish and cannot entertain any header polishs. If, thither are header polishs (for systematizees) you scarcity to link them to a barely cpp polish and upload to GradeScope.

3. Students entertain to spectry their barely cpp polish as ‘project1.cpp’. All inferior event. The autograder allure gait this solely if your program is saved as this spectry.

4. Specimen input polishs and output polishs are fond. Your output should EXACTLY equal the specimen output polish fond. Please cohibit the interspaces and new threads anteriorly your email us effective that the ‘output fitly equales but not cessation the standard events’. Suggest using some stamp of quotation similitude to cohibit your output delay the expected.

5. Students scarcity to entertain solely one header polish(iostream) period uploading to GradeScope. You cannot entertain ‘pch.h’ or ’stdafx.h’.

6. Students cannot entertain 'system pause' at the very end of the cpp polish.

Order a unique copy of this paper
(550 words)

Approximate price: $22

Basic features
  • Free title page and bibliography
  • Unlimited revisions
  • Plagiarism-free guarantee
  • Money-back guarantee
  • 24/7 support
On-demand options
  • Writer’s samples
  • Part-by-part delivery
  • Overnight delivery
  • Copies of used sources
  • Expert Proofreading
Paper format
  • 275 words per page
  • 12 pt Arial/Times New Roman
  • Double line spacing
  • Any citation style (APA, MLA, Chicago/Turabian, Harvard)

Our guarantees

Delivering a high-quality product at a reasonable price is not enough anymore.
That’s why we have developed 5 beneficial guarantees that will make your experience with our service enjoyable, easy, and safe.

Money-back guarantee

You have to be 100% sure of the quality of your product to give a money-back guarantee. This describes us perfectly. Make sure that this guarantee is totally transparent.

Read more

Zero-plagiarism guarantee

Each paper is composed from scratch, according to your instructions. It is then checked by our plagiarism-detection software. There is no gap where plagiarism could squeeze in.

Read more

Free-revision policy

Thanks to our free revisions, there is no way for you to be unsatisfied. We will work on your paper until you are completely happy with the result.

Read more

Privacy policy

Your email is safe, as we store it according to international data protection rules. Your bank details are secure, as we use only reliable payment systems.

Read more

Fair-cooperation guarantee

By sending us your money, you buy the service we provide. Check out our terms and conditions if you prefer business talks to be laid out in official language.

Read more

Calculate the price of your order

550 words
We'll send you the first draft for approval by September 11, 2018 at 10:52 AM
Total price:
$26
The price is based on these factors:
Academic level
Number of pages
Urgency