logo Use SA10RAM to get 10%* Discount.
Order Now logo

Ask This Question To Be Solved By Our ExpertsGet A+ Grade Solution Guaranteed

expert
William BellBusiness
(5/5)

595 Answers

Hire Me
expert
Vincent BirdsallAccounting
(5/5)

593 Answers

Hire Me
expert
Noel HaywardGeneral article writing
(5/5)

608 Answers

Hire Me
expert
Doll JuttHistory
(5/5)

884 Answers

Hire Me
C++ Programming

For each exercise, a hardcopy package must be generated to include the following items: Cover Sheet (use the sample copy include in class/lecture note)

INSTRUCTIONS TO CANDIDATES
ANSWER ALL QUESTIONS

CIS25 – C++ Programming

  1. For each exercise, a hardcopy package must be generated to include the following items:
    • Cover Sheet (use the sample copy include in class/lecture note)

    • Exercise/problem statement

    • Copy of your source file (C++ program named as

cis25Fall2019YournameHw5Ex1.cpp)

  • Copy of output (copy and paste to the end of your program as PROGRAM OUTPUT COMMENT block)

  • Copy of a COMMENT block on Logic_Code_Output Issues (as a separate comment block) after your PROGRAM OUTPUT

  • All other supportive files of h, fractionYourName.cpp, fractionUltilityYourName.h, fractionUtilityYoutName.cpp, PointYourName.h, PointYourName.cpp, PointUltilityYourName.h, PointUtilityYoutName.cpp, etc.

  1. Submitting in class one hard copy for each exercise

  2. Emailing each document as follows,

    • One message for each

    • Attaching the source file that was created in Part a).

    • The SUBJECT line of the message should have the following line:

 

cis25Fall2019YourNameHw5Ex1

  1. Q.E.D.

  2. Code Assignment/Exercise

EXERCISE 1

Consider the following classes:

class FractionYourName; // From previous work and

// to be updated as discussed or needed class PointYourName; // To Be Created

The incomplete class definitions and code are given as follows (and to be updated as given in class discussions),

// Header/Specification Files

/**

  • Program Name: h

  • Discussion: Declaration File -–

  • FractionYourName class

*/

#ifndef FRACTIONYOURNAME_H #define FRACTIONYOURNAME_H

class FractionYourName { public:

// YOUR CODE HERE

//    Must have at least the default constructor,

//                             copy contructor,

//                             destructor, and

//                             assignment operator function

//    and other members

private:

int num;  // numerator will preserve fraction-negativity;

// i.e., negativity of a fraction will be

// assigned to its numerator

int denom; // non-zero value for denominator

};

// your I/O OPERATOR functions here #endif

/**

  • Program Name: h

  • Discussion: Declaration File --

  • PointYourName Class

*/

#ifndef POINTYOURNAME_H #define POINTYOURNAME_H

#include "fractionYourName.h"

// Declarations

class PointYourName { public:

// YOUR CODE HERE

//    Must have at least the default constructor,

//                             copy contructor,

//                             destructor, and

//                             assignment operator function

 

// operations

int getQuadrant() const {

// YOUR CODE HERE

}

int getQuadrant(const PointYourName& p) const {

// YOUR CODE HERE

}

void moveBy(const FractionYourName& delX, const FractionYourName& delY) {

// YOUR CODE HERE

}

void moveBy(int iOld) {  // update as needed

// YOUR CODE HERE

}

void flipByX() {  // update as needed

// YOUR CODE HERE

}

void flipByY() {  // update as needed

// YOUR CODE HERE

}

void flipThroughOrigin() {  // update as needed

// YOUR CODE HERE

}

void print() const {  // update as needed

// YOUR CODE HERE

}

// add operator functions as needed private:

FractionYourName x; // x-coordinate of the point FractionYourName y; // y-coordinate of the point

};

// your I/O OPERATOR functions here #endif

You are asked to

  • Add more member functions and operator functions as needed for the Point class; and

  • Provide complete definitions for all member functions so that the given class is proper and working properly; and

  • Add/Provide complete definitions for all needed non-member functions to perform reasonable tasks; and

  • Save all classes in appropriate *.h and *.cpp files with appropriate names; and

Run a menu program named as with a driver named as cis25Fall2019YourNameHW5Ex1.cpp (and save the output at the end of this driver).

Related Questions

. The fundamental operations of create, read, update, and delete (CRUD) in either Python or Java

CS 340 Milestone One Guidelines and Rubric  Overview: For this assignment, you will implement the fundamental operations of create, read, update,

. Develop a program to emulate a purchase transaction at a retail store. This  program will have two classes, a LineItem class and a Transaction class

Retail Transaction Programming Project  Project Requirements:  Develop a program to emulate a purchase transaction at a retail store. This

. The following program contains five errors. Identify the errors and fix them

7COM1028   Secure Systems Programming   Referral Coursework: Secure

. Accepts the following from a user: Item Name Item Quantity Item Price Allows the user to create a file to store the sales receipt contents

Create a GUI program that:Accepts the following from a user:Item NameItem QuantityItem PriceAllows the user to create a file to store the sales receip

. The final project will encompass developing a web service using a software stack and implementing an industry-standard interface. Regardless of whether you choose to pursue application development goals as a pure developer or as a software engineer

CS 340 Final Project Guidelines and Rubric  Overview The final project will encompass developing a web service using a software stack and impleme

Get Free Quote!

323 Experts Online