Create the roman.h and implement roman class in roman.cpp

Assignment Help C/C++ Programming
Reference no: EM13317606

Submit your assignment on-line using the course web page.

Assignment consists of two tasks. Task 2 is divided into 3 parts.

You are required to submit:
- Task 1: task1.cpp, number.cpp, number.h, task1.txt
- Task 2a: task2a.cpp, roman.cpp, roman.h, task2a.txt

You will be using the same number.cpp and number.h as in task 1.

- Task 2b: task2a.cpp, binary.cpp, binary.h, task2b .txt

You will be using the same number.cpp and number.h as in task 1 and same roman.cpp and roman.h as in task 2a.
- Task 2c: task2c.cpp, task2c.txt

You will be using the same number.cpp and number.h as in task 1, same roman.cpp and roman.h as in task 2a, and same binary.cpp and binary.h as in task 2b.

The .cpp file should have the program code and comments about the algorithm and the coding. We may compile the .cpp files if required. The documentation files should contain the compilation messages and sample runs for each application program. All files must be in pure text format. No PDF, HTML, Word files, Open Office files, RTF etc. and no compression or archiving such as zip, rar, tar etc.

If you are using Codelite, the compilation messages can be copied and pasted with the usual crtl-c and crtl-v. For output of sample runs, right click the title bar of the command window, select EDIT/MARK and then highlight the output. With the output selected, right click the title bar of the command window, select EDIT/COPY. Position your cursor to a (new) text file opened in a text editor such as Notepad, and crtl-v will paste the copied output to the text file.

If you are using MinGW, right click the title bar of the command window; select EDIT/MARK and then high light the output. With the output selected, right click the title bar of the command window, select EDIT/COPY. Position your cursor to a (new) text file opened in a text editor such as Notepad, and crtl-v will paste the copied output to the text file. If you are using Linux, you can cut and paste the output on the terminal window into a text such as vim.

Task 2

Using the Number class as the base class, derive a Roman class:
- The Roman class is the same as Number class except it also stores the integer as a Roman numeral.
- If a Roman is created without an initial value, then the Roman numeral is "INVALID".
- You are not allowed to use arrays, atoi(), atol(), atof(), printf(), sprintf(), fprintf(), vfprintf(), vprintf(),
vsprintf(), scanf(), sscanf(), fscanf(). Feel free to use any other library functions provided by MinGW.

Create the roman.h and implement the Roman class in roman.cpp. Make sure that you put in measures to prevent multiple inclusion of the header file. Test your implementation using task2a.cpp.

Task2a.cpp should:
- Create Roman one
- Without initial value;
- Display one as an integer;
- Display one in US style;
- Display one in EURO style;
- Display one as a Roman numeral;
- Set one to 2014
- Display one as an integer;
- Display one in US style;
- Display one in EURO style;
- Display one as a Roman numeral;
- Create Roman two
- With initial value 22;
- Display two as an integer;
- Display two in US style;
- Display two in EURO style;
- Display two as a Roman numeral;
- Create Roman three
- With initial value 2402;
- Display three as an integer;
- Display three in US style;
- Display three in EURO style;
- Display three as a Roman numeral


Attachment:- Assignment-2-v5.pdf

Reference no: EM13317606

Questions Cloud

Determine the pressure required to increase the jet velocity : Assume the flow is incompressible, irrotational, quasi-steady and the only body force acting is gravity. Determine the pressure, pb, required to increase the jet velocity by 50% relative to the value realized for atmospheric pressure, pa, in the u..
Describe and analyze an algorithm : Describe and analyze an algorithm to determine, given the initial sequence of cards, the maximum number of points that you can collect playing against a perfect opponent.
Determine the coefficient of statics friction of hawser : Determine the (a) the coefficient of statics friction between the hawser and the bollard. (b) the number of times the hawser should be wrapped around the bollard if a 20000 pound force is to be resisted by the same 80 pound force
What is the speed of each sphere when they are far apart : Three small spheres, each have a charge of 3.60 %u03BCC, are arranged in a line, with sphere 2 in the middle. Adjacent spheres are initially 8.70 cm apart. What is the speed of each sphere when they are far apart
Create the roman.h and implement roman class in roman.cpp : Create the roman.h and implement the Roman class in roman.cpp. Make sure that you put in measures to prevent multiple inclusion of the header file. Test your implementation using task2a.cpp.
Find range of value of p for which equilibrium is maintained : a 300 lb block is supported by a rope that was wrapped 1 1/2 times around a horizontal rod. Knowing that the coefficient of static friction is .15 determine the range of values of P for which equilibrium is maintained
What is the size of the aperture : The distance from the center of a circular diffraction pattern to the first dark ring is 15,000 wavelengths on a screen that is 0.85 m away
The short run and the long run in production : Explicit costs and implicit costs,economic profit and accounting profit, and
Determine the wavelength of the light from the laser : A Heliun-Neon laser illuminates a narrow, single slit that is 1850 nm wide. Determine the wavelength of the light from the laser

Reviews

Write a Review

C/C++ Programming Questions & Answers

  Create program that uses functions and reference parameters

Create program that uses functions and reference parameters, and asks user for the outside temperature.

  Write a program using vectors and iterators

Write a program using vectors and iterators that allows a user to maintain a personal list of DVD titles

  Write the code required to analyse and display the data

Calculate and store the average for each row and column. Determine and store the values for the Average Map.

  Write a webservices application

Write a webservices application that does a simple four function calculator

  Iimplement a client-server of the game

Iimplement a client-server version of the rock-paper-scissors-lizard-Spock game.

  Model-view-controller

Explain Model-View-Controller paradigm

  Design a nested program

How many levels of nesting are there in this design?

  Convert celsius temperatures to fahrenheit temperatures

Write a C++ program that converts Celsius Temperatures to Fahrenheit Temperatures.

  Evaluate and output the value in the given base

Write C program that will input two values from the user that are a Value and a Base with which you will evaluate and output the Value in the given Base.

  Design a base class shape with virtual functions

Design a base class shape with virtual functions

  Implementation of classes

Implementation of classes Chart and BarChart. Class barChart chould display a simple textual representation of the data

  Technical paper: memory management

Technical Paper: Memory Management, The intent of this paper is to provide you with an in depth knowledge of how memory is used in executing, your programs and its critical support for applications.

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd