99爱在线视频这里只有精品_窝窝午夜看片成人精品_日韩精品久久久毛片一区二区_亚洲一区二区久久

合肥生活安徽新聞合肥交通合肥房產(chǎn)生活服務(wù)合肥教育合肥招聘合肥旅游文化藝術(shù)合肥美食合肥地圖合肥社保合肥醫(yī)院企業(yè)服務(wù)合肥法律

GameStonk Share Trading代做、java程序設(shè)計(jì)代寫(xiě)

時(shí)間:2024-06-07  來(lái)源:合肥網(wǎng)hfw.cc  作者:hfw.cc 我要糾錯(cuò)



Data Structures Essentials
Assignment 2: GameStonk Share Trading

Background knowledge
In this assignment you will develop a very basic stock market with a stock exchange, brokers that process trades, and trades for different companies’ stocks. In this assignment we have:
A listed company is a company whose shares are bought and sold. Each company has a name, a company code that is an abbreviation of their name, and the current price of their shares.
A trade object contains the number of shares to buy/sell, which company those shares need to be from, and which broker will process that trade.
A broker takes trades from individual users, and puts them in single a queue to process. Because brokers are experts at what they do, they also have a “watchlist” of which companies they recommend people buy shares for. Whilst trades should be processed on a first-in, first-out queue, some unethical brokers might decide to delay when certain trades are processed by putting them at the back of the queue so they could process their own trades first. This is what we’ll be looking at in this assignment.
A stock exchange has a collection of brokers that can buy and sell stocks on it. Each time the stock exchange processes trades, it asks each broker for the next trade in their queue to process. The exchange then processes that trade which causes the company on the trade’s share price to go up or down. This process is then repeated to processes additional trades. 
What you will learn in this assignment
This assignment will help you understand the following concepts:
Creating your own linked lists
Basic use of Priority queues
Basic use of maps/hash maps
compareTo() for comparing objects
Basic exceptions
Unit testing and Junit

Academic Integrity
Any work submitted must represent your own knowledge and efforts. This means that whilst you can use Eclipse’s auto-generation functions for making functions, you cannot use Chat GPT or other larger code-generation tools, or get direct assistance from others to write your code. 
As part of your git history, it should show your knowledge and refactoring of the code to improve it over time, showing that the project submitted was your own work, and was developed over a period of time. 
If we have concerns regarding if your submission is your own, we may interview you about your submission and knowledge of the code and how it works, and how to generate similar code.
Whilst you can look at other materials and resources online to gain understanding and knowledge, the code written must be your own and represent how you think the code should function. Whilst you can talk to other students about your submission at a high level (functions, ideas, class relationships, etc), you are not allowed to share code.

Getting Started
This assignment is an Eclipse project with existing class files that you will be required to complete in varying forms by changing method bodies, return types, creating getters, and setters. In addition to the classes you will be editing, there are a number of Junit tests that are used by a marking program to give you and indication of how well your code is working.  Any changes you make to the class files listed below should be in-line with this requirement specification, any documentation in the code itself, and passing the tests. You do not need to edit any of the test files, or the marker, we will be using our own version of them for marking. However, you may find it useful to edit the test files for debugging purposes.
Getting it running
1.Download the ZIP from the course web page and unzip. 
2.In Eclipse > File > Open Projects from File System and open the project
3.There are two ways you can run the tests:
3.1.The first will run the entire marking program and give you an overall score and marks. Go into the AssignmentMarker.java file in the Junit package and run the file. The console will show you the output from the test marker. Note that you’ll see lots of things going wrong and it doesn’t run completely! That’s ok, we’ll work on that. As you complete more of the code, more of the assignment marker will be able to run.
3.2.The second way is to go into one of the Junit test files specifically, e.g. open up “ListTest.java” and hit run. You should see Junit tests appear in your window and console, showing the output of each test run:

In the bottom left section of the screenshot above it will show a stack trace for any test you click on that failed. This will be what you can use to start debugging what’s happening.
Using the above, you can run the whole marker, or just an individual set of test for a specific class, which makes it easier to focus on one class at a time. As you go through and complete functionality in each class, run the tests for that class to see how successful you were in passing those tests.
Please note that whilst we have provided SOME tests, it does not mean the tests cover everything. Additional tests will be used to mark you assignment, so please review your code and make sure it’s not just passing the tests you have, but also handling any other scenarios it should be.
Getting it into GitHub Desktop
GitHub Desktop is GitHub’s tool for managing code using Git, which is a source control tool that, in short, allows you to take snapshots of your code as you, and easily merge it with what others are working on. For this assignment, you’ll just be using git locally on your own machine to take commits (i.e. a snapshot) of your code as you go through development.
1.Download and install GitHub Desktop from https://desktop.github.com/
2.One installed and open, go File menu > “Open Local Repository”
3.Open the root of the A2 folder you downloaded. You might see a “.git” folder in your download, you want to open the folder that contains this “.git” folder.
3.1.If you get a warning about “This directory does not appear to be a Git repository” you’ve selected the wrong folder. 
4.In the top left you can now switch into the “History” tab and see the initial commit, what files it contained, and what changes were in those files.
5.You can, if needed, revert back to any of your prior commits if you make a mistake and want to “undo” it, however BEWARE! If you do rollback, make sure you don’t lose work you want to keep!
You MUST commit your code at regular intervals. This will teach you to commit your code as you get things working. What you commit doesn’t have to be perfect, and you can refine your code later on, but it is important to commit your work as you go so that you have snapshots showing it’s development over time, and your trial-and-error as you learn and improve on it.
Your git repository and its history are part of your marks! Make sure to commit each time you get things to a good point.
There are lots of tutorials online for using GitHub Desktop, with their official documentation for making commits available at https://docs.github.com/en/desktop/contributing-and-collaborating-using-github-desktop/making-changes-in-a-branch/committing-and-reviewing-changes-to-your-project. 

Completing the assignment
Please review the below, along with the actual source files comments, and the tests themselves for additional information. 
You may be required to change the parameter types or return types of function calls as part of the assignment. You’ll need to use your understanding of how the code should operate to make the required changes.
Step One – DSEList.java
In part 1, you will create your own implementation of the Java LinkedList Collections class. There is an «interface» provided for List. In Step Two, you will then use your Linked List implementation as the basis for making a generic version that can store any type of object. 
DSEList will extend the List class defined in List.java. The implementation will be a double-linked list and must implement the abstract methods from List.java. 
DSEList should have one data member: public Node head. Others can be added if you require them. 
The Node objects used by the list store basic String objects.
Implement the following methods in the List class: 
Constructor: implement a blank constructor which takes no parameters. 
Constructor: implement a constructor accepting one Node (containing a String object). The constructor should set head to the given Node. 
Copy constructor: implement a copy constructor accepting a DSEList object. The copy constructor should perform a deep copy of the DSEList passed to the constructor: the new DSEList should not contain references to the Node objects in the second DSEList. (The two DSELists should be independent: changing the contents of Node objects in one DSEList should not affect the other). 
public boolean add(String obj): The add method should append the specified object to the end of the List. 
public boolean isEmpty() 
public int size() 
public String toString(): this should return a String created by concatenating each Nodes toString(). A single space: ‘ ’ should be inserted between each Nodes toString(). No trailing space should be inserted. For example, if the list contains 3 Node objects, an appropriate toString() return value could be ‘1 2 3’, but not ‘123’ or ‘1 2 3 ’ [note the trailing whitespace]. For further details, refer to the unit tests supplied with the assignment. 
public boolean equals(Object other): two DSEList objects are equal if they contain the same Strings in the same order. 
Step Two – DSEListGeneric.java
The second part of the assignment is to take the code you have written for your list and make it generic. This will allow the list’s nodes to store ANY objects, not just Strings. You should have to write almost no code for this step, instead you should only need copy and refactor your existing code from the functions in DSEList.java into DSEListGeneric.java, and make very small changes to it to enable generics.  The generic list should use the NodeGeneric class for its nodes.
DSEListGeneric should support the same functions as above for DSEList, however any references to the String type that the list stores should be replaced with the generic type that’s passed in when the generic list is created at runtime. Again, you should have to add no additional logic for this step, rather you are just copying and refactoring your existing DSEList functions into DSEListGeneric with very minor changes to the signature of methods and their contents. As a hint for converting a class from a non-generic class into a generic class, compare the Node and NodeGeneric classes. They achieve the same thing, however the second one supports generics.
Step Three
Now that we’ve got the ability to store a list of things, we can start to build out the rest of the trading simulator. Generally you should be able to go through this list top-to-bottom in order when implementing things, however occasionally you may need to complete or at least start a function listed later in the document if it’s required by a function you’re trying to complete. 
ListedCompany.java
A listed company is a company that can have its shares bought and sold on a securities exchange.
public String getName(): public getter for "name";
public String getCode(): public getting for "code"
public int getCurrentPrice(): public getter for "currentPrice"
public ListedCompany(String code, String name, int currentPrice): Should store the three parameters into the instance variables
public int processTrade(int quantity): should increase or decrease the value of the currentPrice variable depending on the quantity of stock as the parameter. The price should increase by "quantity / 100" amount, and never drop below 1 in price. For a “sell” the quantity will be negative (price goes down), and positive for a buy (price goes up).
StockBroker.java
Stock brokers take trade orders on behalf of others and process the trades on the securities exchange. The broker must track all their pending orders so they know which trade to process next. Brokers also track a watchlist of companies they advise their clients to purchase, however some dodgy brokers may encourage users to buy a certain stock, but then not process their trades on time as expected!
private PriorityQueue<Trade> pendingTrades: Should be an instance variable using Java’s PriorityQueue class to store Trade objects.
private DSEListGeneric<String> watchlist – Should be an instance variable of the DSEListGeneric class to store objects of type String.
public DSEListGeneric<String> getWatchlist() – Public getter for watchlist. It should return a new list, rather than the current list. Modifying the list returned by getWatchlist (e.g. removing an item) should not affect the original version of the list held by the StockBroker.
public Boolean addWatchlist(String companyCode) – Adds a company code to the watch list. Return false if item is already in the list or is null, true otherwise if added to the list
public String getName() – Gets the broker’s name.
public StockBroker(String name) – Create a broker with given name.
public boolean placeOrder(Trade order) – Adds the Trade to the pendingTrades list if it's not null and not already in there.
public Trade getNextTrade()
public int getPendingTradeCount()
Trade.java
Trade objects represent a specific number of shares to be bought in a specific company. Each trade object is also associated with the stock broker who will be processing that trade.
public Trade(StockBroker broker, String listedCompanyCode, int shareQuantity): Should store the three parameters into the instance variables
public int compareTo(Trade other): Compare this trade with another trade. Please see JavaDoc in code for more informationStep Four (Optional) – Command Line Interface
UntradedCompanyException.java
This is class should be an Exception that can be thrown when an unknown company code is used.
public UntradedCompanyException(String companyCode): This should allow any exception thrown using this class to show the message “TSLA is not a listed company on this exchange”, assuming the companyCode “TSLA” was passed in as the parameter.
SecuritiesExchange.java
public SecuritiesExchange(String name)
public boolean addCompany(ListedCompany company)
public boolean addBroker(StockBroker broker)
public int processTradeRound() throws UntradedCompanyException
Optional Step Four (no marks allocated)
No marks are allocated for this final step and it is completely optional. You can still obtain a 100% for the assignment without completing this final section.
SecuritiesExchange has an additional function runCommandLineExchange(), that is sent a Scanner object. If you’re looking to push yourself a little further, this should act as a stub where you can develop your own list of commands to be processed by the exchange to add trades to brokers, process a trade round and exit. Whilst the stub for this method is given to you, as is a simple setup to automate testing of commands from a file, they will need to be extended by you. Once you can process commands from command line or a text file, who knows what’s next?!?!?! Accepting trade orders over a network?
public int runCommandLineExchange(Scanner sc)

Marking scheme
Ensure clean, consistent coding style. There is no official style guide for the assignment other than using the standard Java conventions. We can only award marks for code you have written, so if you don’t have any code, you don’t get any marks for style.
Your code should be commented and be easy for us to follow and understand, without too many comments. If it is not easily apparent what something is doing, ensure you comment what it’s doing and why. We can only award marks for code you have written, so if you don’t have any code, you don’t get any marks for commenting.
Marks summary is below. As part of the marking scheme, we will also be reviewing your Git history for that part. If you haven’t committed that section/class appropriately, for example you just a large, fully functional and complete class in one commit, you may lose up to 50% of the marks for that element. Smaller/one-line functions obviously can only be committed once complete, which is perfectly fine, but for your larger elements, we need to be able to see it’s history and how it has evolved.
Code passes required tests
Your code passes the tests we run on it. Whilst you are given some tests for the classes, we may use additional tests for the final marking. The proportion of marks per class will be similar to the assignment marker you are given. This means the majority of the marks will still be for the List and ListGeneric classes. Please see the marking program for further breakdown of marks.    80%
Code style
Clean, consistent coding style. There is no official style guide for the assignment other than using the standard Java conventions. We can only award marks for code you have written, so if you don’t have any code, you don’t get any marks for style.    10%
Code commenting
Your code should be commented and be easy for us to follow and understand, without too many comments. If it is not easily apparent what something is doing, ensure you comment what it’s doing and why. We can only award marks for code you have written, so if you don’t have any code, you don’t get any marks for commenting.    10%
Total    100%

Submitting
Please ZIP your entire root folder of the project and upload to LearnOnline. This folder should include your src directory. 
We must receive your .java source files from the “src” folder in order to mark any code.
Due date
Please see the course website for the due date. Unless you have an extension, there is NO LATE SUBMISSION. Late submission without an extension will result in a mark of 0.
Please regularly upload a snapshot of your code to the site so that we have a copy. This means if something does happen and you can’t submit your latest version, we still have an earlier version to mark.
Extensions
If you need an extension for an on-going issue, e.g. medical, access plan, etc., please submit a request via LearnOnline to be reviewed. If you have any issues please email me directly via email. Having other assignments or work commitments is not a valid reason for extension.

請(qǐng)加QQ:99515681  郵箱:99515681@qq.com   WX:codinghelp





 

掃一掃在手機(jī)打開(kāi)當(dāng)前頁(yè)
  • 上一篇:臺(tái)灣居民在上海能越南簽證嗎(臺(tái)灣居民申請(qǐng)?jiān)侥虾炞C流程)
  • 下一篇:菲律賓入境簽證在哪里辦 什么時(shí)候去辦比較合適
  • 無(wú)相關(guān)信息
    合肥生活資訊

    合肥圖文信息
    急尋熱仿真分析?代做熱仿真服務(wù)+熱設(shè)計(jì)優(yōu)化
    急尋熱仿真分析?代做熱仿真服務(wù)+熱設(shè)計(jì)優(yōu)化
    出評(píng) 開(kāi)團(tuán)工具
    出評(píng) 開(kāi)團(tuán)工具
    挖掘機(jī)濾芯提升發(fā)動(dòng)機(jī)性能
    挖掘機(jī)濾芯提升發(fā)動(dòng)機(jī)性能
    海信羅馬假日洗衣機(jī)亮相AWE  復(fù)古美學(xué)與現(xiàn)代科技完美結(jié)合
    海信羅馬假日洗衣機(jī)亮相AWE 復(fù)古美學(xué)與現(xiàn)代
    合肥機(jī)場(chǎng)巴士4號(hào)線(xiàn)
    合肥機(jī)場(chǎng)巴士4號(hào)線(xiàn)
    合肥機(jī)場(chǎng)巴士3號(hào)線(xiàn)
    合肥機(jī)場(chǎng)巴士3號(hào)線(xiàn)
    合肥機(jī)場(chǎng)巴士2號(hào)線(xiàn)
    合肥機(jī)場(chǎng)巴士2號(hào)線(xiàn)
    合肥機(jī)場(chǎng)巴士1號(hào)線(xiàn)
    合肥機(jī)場(chǎng)巴士1號(hào)線(xiàn)
  • 短信驗(yàn)證碼 豆包 幣安下載 AI生圖 目錄網(wǎng)

    關(guān)于我們 | 打賞支持 | 廣告服務(wù) | 聯(lián)系我們 | 網(wǎng)站地圖 | 免責(zé)聲明 | 幫助中心 | 友情鏈接 |

    Copyright © 2025 hfw.cc Inc. All Rights Reserved. 合肥網(wǎng) 版權(quán)所有
    ICP備06013414號(hào)-3 公安備 42010502001045

    99爱在线视频这里只有精品_窝窝午夜看片成人精品_日韩精品久久久毛片一区二区_亚洲一区二区久久

          9000px;">

                在线播放一区二区三区| 欧美日韩一区国产| 亚洲精品免费视频| 久久久夜色精品亚洲| 777久久久精品| 3d动漫精品啪啪一区二区竹菊| 色综合天天综合网天天看片| 福利一区福利二区| 夫妻av一区二区| 成人av资源在线| 91片在线免费观看| 91精彩视频在线观看| 一本大道综合伊人精品热热| 欧洲av一区二区嗯嗯嗯啊| 欧美私模裸体表演在线观看| 欧美日韩激情一区二区三区| 日韩一区二区在线免费观看| 亚洲精品在线观| 国产精品水嫩水嫩| 亚洲乱码国产乱码精品精的特点 | 午夜国产不卡在线观看视频| 亚洲成av人影院| 免费久久99精品国产| 精品一区二区成人精品| 成人激情小说乱人伦| 色婷婷av一区| 日韩手机在线导航| 日本一区二区三区在线不卡| 综合欧美亚洲日本| 日本免费在线视频不卡一不卡二| 国产精品自拍在线| 色诱视频网站一区| 日韩视频一区二区三区在线播放 | 国产精品一区三区| 色综合久久久久| 日韩一级片在线播放| 国产亚洲精品久| 亚洲精品成人在线| 韩日精品视频一区| 在线观看精品一区| 国产午夜精品久久久久久免费视| 一区二区三区中文字幕电影| 麻豆成人91精品二区三区| 不卡的电视剧免费网站有什么| 欧美日韩在线一区二区| 国产欧美综合在线| 日韩av电影免费观看高清完整版| a美女胸又www黄视频久久| 欧美日韩一级二级| 最新成人av在线| 国产乱码精品一区二区三区av| 91电影在线观看| 国产欧美精品一区aⅴ影院| 天涯成人国产亚洲精品一区av| 成人性生交大片免费看中文网站| 欧美一区二区在线观看| 亚洲卡通动漫在线| 不卡一区二区在线| 国产欧美久久久精品影院| 美女一区二区视频| 在线免费观看一区| 国产精品黄色在线观看| 国产综合成人久久大片91| 欧美日韩国产在线播放网站| 国产精品激情偷乱一区二区∴| 国内久久精品视频| 日韩三级电影网址| 同产精品九九九| 欧美亚洲国产一区二区三区va| 日本一区二区三区四区在线视频 | 国产美女精品人人做人人爽| 91精品久久久久久久99蜜桃 | 亚洲手机成人高清视频| 国产乱子伦一区二区三区国色天香| 精品视频123区在线观看| 亚洲高清免费视频| 亚洲日本免费电影| 国产成人丝袜美腿| 国产麻豆欧美日韩一区| 欧美一区在线视频| 五月天丁香久久| 欧美日本韩国一区二区三区视频 | 一区二区三区鲁丝不卡| 成熟亚洲日本毛茸茸凸凹| 久久一夜天堂av一区二区三区| 青青草国产成人99久久| 日韩一区二区三区在线| 蜜臀久久99精品久久久久久9| 欧美福利视频导航| 美女在线一区二区| 精品免费日韩av| 国产精品夜夜嗨| 久久婷婷国产综合精品青草| 国产精品综合在线视频| 欧美韩日一区二区三区四区| youjizz久久| 一区二区三区日本| 欧美肥妇bbw| 国内精品伊人久久久久av一坑| 精品国产不卡一区二区三区| 国产高清不卡二三区| 国产精品不卡一区| 欧美私人免费视频| 麻豆一区二区三| 国产蜜臀av在线一区二区三区| 成人免费观看av| 亚洲一区二区三区激情| 日韩小视频在线观看专区| 国产乱一区二区| 亚洲精品视频在线看| 69久久99精品久久久久婷婷| 韩国女主播一区| 亚洲色图一区二区| 欧美电影免费观看高清完整版 | 中文字幕免费观看一区| 91啪在线观看| 视频在线在亚洲| 国产精品美女久久久久高潮| 欧美亚洲免费在线一区| 国产一区二区精品久久91| 亚洲乱码国产乱码精品精98午夜| 欧美一区二区在线观看| 99re这里都是精品| 久久精品国产成人一区二区三区 | 成人黄色777网| 日韩av一区二区三区四区| 国产精品色噜噜| 日韩午夜中文字幕| 在线精品视频免费观看| 国产精品88888| 午夜电影一区二区| 亚洲欧美另类小说| 国产亚洲va综合人人澡精品| 欧美日韩你懂得| av亚洲精华国产精华| 激情综合色综合久久| 午夜国产精品一区| 亚洲综合久久久久| 中文字幕人成不卡一区| 久久综合九色综合欧美98| 欧美区视频在线观看| 色综合久久综合中文综合网| 国产91丝袜在线播放0| 久久97超碰国产精品超碰| 亚洲激情综合网| 国产精品国产精品国产专区不片| 精品久久久久久久久久久久久久久 | 亚洲欧洲日韩一区二区三区| 精品蜜桃在线看| 欧美一区二区三区在线观看| 在线国产电影不卡| 91视频com| 色综合网色综合| 成人av在线网| 国产高清久久久| 国产一区二区在线影院| 久久精品噜噜噜成人88aⅴ| 亚洲成人动漫一区| 亚洲丶国产丶欧美一区二区三区| 亚洲精品欧美专区| 亚洲视频资源在线| 亚洲人成在线观看一区二区| 国产精品美女久久久久久久网站| 国产欧美一区二区在线观看| 国产欧美中文在线| 中文一区在线播放| 国产精品国产a级| 国产精品国产三级国产| 亚洲日本免费电影| 亚洲乱码国产乱码精品精的特点| 亚洲柠檬福利资源导航| 亚洲精品日日夜夜| 日韩综合小视频| 麻豆精品久久精品色综合| 极品美女销魂一区二区三区免费| 国产麻豆一精品一av一免费| 成人一级视频在线观看| 色婷婷av一区| 在线电影欧美成精品| 欧美电影免费提供在线观看| 久久夜色精品国产噜噜av| 中文字幕在线不卡| 亚洲午夜精品17c| 免费人成黄页网站在线一区二区| 精品一区二区成人精品| 国产白丝网站精品污在线入口| 成人av在线资源网| 一本在线高清不卡dvd| 色婷婷av一区二区三区gif| 欧美在线观看视频一区二区三区 | 国产精品久久一卡二卡| 亚洲乱码日产精品bd| 天天av天天翘天天综合网色鬼国产 | 亚洲综合色噜噜狠狠| 日韩国产精品大片| 国产精品一线二线三线精华| 97久久久精品综合88久久| 欧美一区二区三区视频在线 | 亚洲一区二区三区爽爽爽爽爽 | 久久99精品国产麻豆婷婷 |