国产人妻人伦精品_欧美一区二区三区图_亚洲欧洲久久_日韩美女av在线免费观看

合肥生活安徽新聞合肥交通合肥房產生活服務合肥教育合肥招聘合肥旅游文化藝術合肥美食合肥地圖合肥社保合肥醫院企業服務合肥法律

代寫CSCE 240 – Programming

時間:2024-03-06  來源:合肥網hfw.cc  作者:hfw.cc 我要糾錯


Due: 11:59pm on Monday, March 18

Purpose – Implement the following two classes

Class 1 – MonetaryUnit

Create a MonetaryUnit class that holds the name (a string), monetary symbol (a string) and the amount of the monetary unit that is equivalent to one US dollar (a double) as private data members.

The class must include the following public member functions:

A SetName function that has a string as its parameter and sets the name of the monetary unit to the string as long as the string isn’t empty (has a length of at least 1). The function should return true if the name is set to the function’s argument, and false otherwise.

A GetName function that returns a copy of the name of the monetary unit.

A SetSymbol function that takes a has as its parameter and sets the monetary symbol to the string as long as the string isn’t empty (has a length of at least 1). The function should return true if the symbol is set to the function’s argument, and false otherwise.

A GetSymbol function that returns a copy of the monetary unit’s symbol.

A SetAmountEquivalentTo1Dollar function that has a double as its parameter and sets the double data member equal to the function’s argument as long as the argument is positive. The function should return true if the data member is set to the function’s argument, and false otherwise.

A GetAmountEquivalentTo1Dollar function that returns a copy of the double data member.

A constructor that takes a string for the name, a string for the symbol, and a double for the amount equivalent to one dollar as parameters. The parameters should have default arguments of “US dollars”, “$”, and 1, respectively.

The class must include the following overloaded operator:

Overload the == operator to return true if two MonetaryUnit objects hold the same private data member values.

Review initial tests for the functionality of the class in the following files:

testMonetaryUnitName.cc, testMonetaryUnitSymbol.cc,

testMonetaryUnitAmountEquivalentTo1Dollar.cc, testMonetaryUnitConstructor.cc, and

testMonetaryUnitEquivalent.cc.

If you place all of the attached files in the same directory, you can run the initial tests with the commands

make testMonetaryUnitName

make testMonetaryUnitSymbol

make testMonetaryUnitAmountEquivalentTo1Dollar

make testMonetaryUnitConstructor

make testMonetaryUnitEquivalent

You are strongly encouraged to create more rigorous tests.

Class 2 – MonetaryAmount

Create a MonetaryAmount class that has a value (a double) and a monetary unit (a MonetaryUnit object) as data members.

The class must include the following public member functions:

A GetValue and GetUnit accessor functions that return copies of the MonetaryAmount’s value and MonetaryUnit data members, respectively.

A constructor that takes a double and a constant reference to a MonetaryUnit as parameters. The parameters should have default arguments of 0 and US dollars (MonetaryUnit(“US dollars”, “$”, 1)), respectively. The constructor should set up the new MonetaryAmount object with the parameters’ values.

A ConvertToUnit function that has a constant reference to a MonetaryUnit as its parameter. The function should update the value and the MonetaryUnit data members so that the object holds an equivalent monetary amount in the updated units. For example, assume that an object originally holds 3 US dollars, and that 0.92 Euros is equivalent to 1 US dollar. Converting the object to Euros should update the monetary unit of the object to Euros and it should update the value of the object to 2.76. See testMonetaryAmountConvertToUnit.cc for additional examples.

The class must include the following public static data member:

A public static boolean data member named display_unit_name that holds the value true if monetary amounts are to display with the value followed by a space and the monetary unit name (e.g. “3.25 US dollars”) and false if monetary amounts display with the monetary symbol followed by the numeric value (e.g. “$3.25”). Initialize the value of this data member to false.

This data member is used by the << operator and will be tested in

The class must include the following overloaded operators:

Overload the == operator to return true if two MonetaryAmount objects hold the equivalent amounts, and false if they do not. See testMonetaryAmountEquivalent.cc for examples.

Overload the < operator to return true if the MonetaryAmount object on the left of the operator represents a smaller monetary amount than the MonetaryAmount on the right, and false otherwise. See testMonetaryAmountLessThan.cc for examples.

Overload the > operator to return true if the MonetaryAmount oject on the left of the operator represents a larger monetary amount than the MonetaryAmount on the right, and false otherwise. See testMonetaryAmountGreaterThan.cc for examples.

Overload the << operator to output a MonetaryAmount object in the format specified by the static data member display_unit_name. See testMonetaryAmountCreateOutput.cc and expectedoutput.txt for example output statements and the output they should create.

Overload the + operator to take two MonetaryAmount objects as operands and returns a MonetaryAmount object holding the sum of the two objects in the units of the left operand. See testMonetaryAmountAddition.cc for examples.

Review initial tests for the functionality of the class in the following attached files: testMonetaryAmountConstructor.cc, testMonetaryAmountConvertToUnit.cc, testMonetaryAmountEquivalent.cc, testMonetaryAmountLessThan.cc, testMonetaryAmountGreaterThan.cc, testMonetaryAmountCreateOutput.cc, expectedoutput.txt, and testMonetaryAmountAddition.cc

If you place all of the attached files in the same directory, you can run the initial tests with the commands

make testMonetaryAmountConstructor

make testMonetaryAmountConvertToUnit

make testMonetaryAmountEquivalent

make testMonetaryAmountLessThan

make testMonetaryAmountGreaterThan

make testMonetaryAmountOutput

make testMonetaryAmountAddition

You are strongly encouraged to create more rigorous tests.

Specifications

- Add all code for the definition of the MonetaryUnit class in a header file named MonetaryUnit.h

- Include all of the necessary code for the MonetaryUnit class, including the implementations of the public member functions and the overloaded == operator, in a source file named MonetaryUnit.cc

- Add all code for the definition of the MonetaryAmount class in a header file named MonetaryAmount.h

- Include all of the necessary code for the MonetaryAmount class, including the implementations of the public member functions and operators, in a source file named MonetaryAmount.cc

- You will submit a zip file (only a zip file will be accepted) containing MonetaryUnit.h, MonetaryUnit.cc, MonetaryAmount.h and MonetaryAmount.cc to the assignment in Blackboard.

- Source files must compile and run on a computer of the instructor’s choosing in the Linux lab (see your course syllabus for additional details).

- Your programming assignment will be graded with modified versions of the test files

Grade Breakdown

Style MonetaryUnit.h: 0.25 points

Style MonetaryUnit.cc: 0.25 points

Style MonetaryAmount.h: 0.25 points

Style MonetaryAmount.cc: 0.25 points

Documentation: 1 point

Clean compilation of MonetaryUnit.cc: 0.5 points

Clean compilation of MonetaryAmount.cc: 0.5 points

Passes instructor’s modified testMonetaryUnitName.cc tests: 0.5 points

Passes instructor’s modified testMonetaryUnitSymbol.cc tests: 0.5 points

Passes instructor’s modified testMonetaryUnitAmountEquivalentTo1Dollar.cc tests:

0.5 points

Passes

instructor’s modified

testMonetaryUnitConstructor.cc tests: 0.5 points

Passes

instructor’s modified

testMonetaryUnitEquivalent.cc tests: 0.5 points

Passes

instructor’s modified

testMonetaryAmountConstructor.cc tests: 0.5 points

Passes

instructor’s modified

testMonetaryAmountConvertToUnit.cc tests: 1 point

Passes

instructor’s modified

testMonetaryAmountEquivalent.cc tests: 0.5 points

Passes

instructor’s modified

testMonetaryAmountLessThan.cc tests: 0.5 points

Passes

instructor’s modified

testMonetaryAmountGreaterThan.cc tests: 0.5 points

Passes instructor’s modified MonetaryAmount << operator tests: 1 point

Passes instructor’s modified testMonetaryAmountAddition.cc.cc tests: 0.5 point

The penalty for late program submissions is 10% per day, with no submission accepted after 3 days.

請加QQ:99515681  郵箱:99515681@qq.com   WX:codehelp 

掃一掃在手機打開當前頁
  • 上一篇:代寫MMME1027、代做Matlab語言程序
  • 下一篇:代做CSCI 241 Data Structures
  • 無相關信息
    合肥生活資訊

    合肥圖文信息
    流體CFD仿真分析_代做咨詢服務_Fluent 仿真技術服務
    流體CFD仿真分析_代做咨詢服務_Fluent 仿真
    結構仿真分析服務_CAE代做咨詢外包_剛強度疲勞振動
    結構仿真分析服務_CAE代做咨詢外包_剛強度疲
    流體cfd仿真分析服務 7類仿真分析代做服務40個行業
    流體cfd仿真分析服務 7類仿真分析代做服務4
    超全面的拼多多電商運營技巧,多多開團助手,多多出評軟件徽y1698861
    超全面的拼多多電商運營技巧,多多開團助手
    CAE有限元仿真分析團隊,2026仿真代做咨詢服務平臺
    CAE有限元仿真分析團隊,2026仿真代做咨詢服
    釘釘簽到打卡位置修改神器,2026怎么修改定位在范圍內
    釘釘簽到打卡位置修改神器,2026怎么修改定
    2025年10月份更新拼多多改銷助手小象助手多多出評軟件
    2025年10月份更新拼多多改銷助手小象助手多
    有限元分析 CAE仿真分析服務-企業/產品研發/客戶要求/設計優化
    有限元分析 CAE仿真分析服務-企業/產品研發
  • 短信驗證碼 寵物飼養 十大衛浴品牌排行 目錄網 排行網

    關于我們 | 打賞支持 | 廣告服務 | 聯系我們 | 網站地圖 | 免責聲明 | 幫助中心 | 友情鏈接 |

    Copyright © 2025 hfw.cc Inc. All Rights Reserved. 合肥網 版權所有
    ICP備06013414號-3 公安備 42010502001045

    国产人妻人伦精品_欧美一区二区三区图_亚洲欧洲久久_日韩美女av在线免费观看
    狠狠色综合色区| 911国产网站尤物在线观看| 一区二区精品免费视频| 久久亚洲欧美日韩精品专区| 国产精品入口免费视频一| 久久精品国产亚洲一区二区| 久久福利一区二区| 久久国产手机看片| 久久精品男人天堂| 久久精品国产欧美激情| 国产精品人人做人人爽| 国产精品美女免费看| 久久不射热爱视频精品| 欧美激情第三页| 亚洲激情电影在线| 少妇人妻在线视频| 日本午夜一区二区三区| 欧美中文字幕在线观看| 欧美在线一区二区三区四区| 狠狠干 狠狠操| 国产伦精品一区二区三区| 国产精品一区二区欧美| 91精品国产高清久久久久久91 | 国产爆乳无码一区二区麻豆| 久久精品无码中文字幕| 国产精品普通话| 久久久久久国产| 偷拍视频一区二区| 日韩视频专区| 欧美性受xxxx黑人猛交| 国产一区视频免费观看| 91国语精品自产拍在线观看性色| 色777狠狠综合秋免鲁丝| 麻豆国产精品va在线观看不卡| 一区精品在线| 欧洲视频一区二区三区| 国产精品一区视频网站| 久久99九九| 美女av一区二区三区| 视频一区国产精品| 经典三级在线视频| 91九色蝌蚪国产| 久久黄色av网站| 一本久道高清无码视频| 日本一区高清在线视频| 麻豆中文字幕在线观看| 久久婷婷开心| 欧美黄网免费在线观看| 欧美亚洲伦理www| 131美女爱做视频| 久久国产精品久久久久| 欧美一区三区二区在线观看| 91精品国产综合久久久久久蜜臀| 国产精品久久在线观看| 色综合视频二区偷拍在线| 国产欧美123| 国产精品青草久久久久福利99| 视频一区国产精品| www.欧美黄色| 欧美另类69精品久久久久9999| 亚洲 自拍 另类小说综合图区| 国产综合在线看| 日韩中文字幕视频| 天天操天天干天天玩| 国产精品夜夜夜爽张柏芝| 国产精品久久9| 欧洲熟妇精品视频| 久久99久久99精品蜜柚传媒| 亚洲第一页在线视频| 国产精品亚洲αv天堂无码| 国产精品久久久久久久久久久久冷 | 欧美精品在线网站| 人妻无码久久一区二区三区免费| 成人国产一区二区三区| 欧美成人第一页| 女女同性女同一区二区三区91| 久久综合狠狠综合久久综青草| 久久6精品影院| 国产在线一区二区三区播放| www.欧美免费| 人人做人人澡人人爽欧美| 久久男人资源视频| 午夜欧美大片免费观看| 91精品视频网站| 亚洲欧洲在线一区| 成人久久久久久久| 九色成人免费视频| 国内精品久久久久久中文字幕| 丝袜一区二区三区| 欧美日韩另类丝袜其他| 国产精品丝袜高跟| 国模精品娜娜一二三区| 精品国产一区二区三区四区vr| 国产在线观看不卡| 欧美日本精品在线| 成人免费视频91| 亚洲精品国产精品久久| 91久久精品久久国产性色也91| 欧美极品欧美精品欧美视频| 成人一级生活片| 亚洲精品一区国产精品| 91av国产在线| 日韩国产一级片| 国产精品视频网址| 国内精品久久久久影院优| 不卡av日日日| 97欧美精品一区二区三区| 日韩一级片一区二区| 久99久视频| 黄色a级片免费| 久久99精品久久久久久琪琪| 成人短视频在线观看免费| 午夜精品久久久久久久99热浪潮| 国产成人福利视频| 黄页网站大全在线观看| 国产精品第七影院| 国产精品永久在线| 午夜精品久久久久久久99热| 久久久久久久久综合| 男人的天堂99| 在线视频91| 日韩视频中文字幕| 国产在线视频一区| 亚洲精品一区二区三区樱花| 久久久久在线观看| 国产一区二区丝袜| 欧美一区二区三区精美影视| 久久九九有精品国产23| 国产伦精品一区二区三毛| 日韩在线三区| 欧美另类第一页| 国产精品88久久久久久妇女| 欧美又粗又长又爽做受| 九九热视频这里只有精品| 国产xxxxx在线观看| 国产主播一区二区三区四区| 动漫3d精品一区二区三区| 国产精品女主播| 国产精品18毛片一区二区| 黄色91av| 日韩中文字幕在线视频观看| 国产精品高清在线| 久久综合狠狠综合久久综青草| 美国av一区二区三区| 日本一本a高清免费不卡| 久久91亚洲精品中文字幕| 久久久久久久久久久av| 国产一区二区三区黄| 日本公妇乱淫免费视频一区三区| 色综合久久88| 国产精品入口芒果| 国产h视频在线播放| 成人在线免费观看一区| 欧美激情视频一区二区三区| 少妇精品久久久久久久久久| 久久国产精品久久久| 久久精品国产清自在天天线 | 国产精品a久久久久久| 不卡日韩av| 黄色激情在线视频| 日本不卡一区二区三区在线观看| 亚洲在线免费看| 国产精品国产三级国产专区51 | 欧美黄网免费在线观看| 国产精品日韩在线| 久久国产精品一区二区三区| 99在线热播| 国产男女猛烈无遮挡91| 激情视频小说图片| 欧美专区国产专区| 日韩三级在线播放| 色999五月色| 欧美一区二区三区四区在线观看地址| 久久艳片www.17c.com| 日韩中文字幕免费看| 久久99欧美| 国产激情视频一区| 久久人人爽人人爽人人片av高清 | 久久av在线播放| 国产精品精品软件视频| 久久精品视频在线| 久久精品国产成人精品| 久久久999国产精品| www.国产一区| 国产成人精品优优av| 国产成人久久久| 国产成人久久婷婷精品流白浆| 国产chinese精品一区二区| 久久免费看毛片| 久久久久狠狠高潮亚洲精品| 久久久视频在线| 久久狠狠久久综合桃花| 日韩视频精品在线| 久久天天躁狠狠躁夜夜av| 国产精品视频午夜| 国产精品国模大尺度私拍| 欧美久久久精品| 亚洲中文字幕无码av永久| 亚洲一区二区三区精品在线观看| 亚洲精品一区二区三区四区五区|