久久久久久精品无码人妻_青春草无码精品视频在线观_无码精品国产VA在线观看_国产色无码专区在线观看

CS1083代做、代寫Java設計編程

時間:2024-03-03  來源:  作者: 我要糾錯



Module 9 Assignment
Worth 2% of your total course grade
CS1083 – Introduction to Computer Programming II (in Java)
Online Open Entry Version
Instructor: Andrew McAllister
Assignment Objectives
The purpose of this assignment is to give you practice:
• working with linked lists
General Instructions for All Assignments
• Follow the instructions in the document "Java Coding Guidelines.pdf" available
within the "Start Here" module, under the "Assignments" topic.
• For each .java file you create, include a javadoc comment (one that begins with
/**) at the beginning of the file that describes that Java class. This comment block
should include a line that begins with @author followed by your name and
student number on the same line. (Note: inclusion of this comment is part of the
instructions given in "Java Coding Guidelines.pdf")
• Include comments throughout your programs to explain any non-obvious portions
of your code.
• It is recommended that you create a separate folder on your computer for each
assignment. You might even wish to create separate sub-folders within an
assignment folder if the assignment has multiple parts. Keeping your work
organized makes it easier to find things later when you want to review what you
have done.
• Few things in life are more frustrating than losing your work while working on an
assignment. Get in the habit of saving frequently when working on an
assignment. Also, regularly make backup copies of any files you create as part of
your work for this course.
Assignment Guide
• Feel free to email your instructor if you need help in completing an assignment.
When you do so, please attach to the email a copy of *all* files required to
compile and run the program you are asking about, even if you downloaded
those files from D2L. (Otherwise the instructor will have to figure out what files
are missing and then go looking for them. Make it convenient to help you.) Also
describe the problem you are encountering and the specific help you would like
to receive.
• Submitting your assignment involves creating a pdf file and uploading that single
file to the assignment drop box on D2L. In general, that file will tend to include all
Java code you wrote for the assignment, plus any output from running your
programs that the assignment instructions specify you should capture. Specific
submission instructions are included at the end of each assignment.
• To create the pdf file for each assignment, begin by opening a new document
using the word processing program of your choice. Save the document using the
name “Your Name CS1083 Module x Assignment Submission.docx” Replace x
with the correct module number. “docx” may be different depending on which
word processing software you choose to use.
• If you don’t already have a word processor, UNB students are able to use
Microsoft Office 365 (includes Microsoft Word) for free, which can be accessed
by logging in to MyUNB.
• At the beginning of your submission document enter your name, your student
number, CS1083, the assignment name (this one is “Module 2 Assignment”), and
the date. It doesn’t matter if the date is when you started working on the
assignment or when you submit it – either will do.
• You can add content to your submission document as you work on the various
questions in the assignment. Clearly label each part of the assignment (“Part A”
etc.) in your document. Be sure to save frequently as you work on this document.
• When your document is complete, save / export it as a pdf file. Always make sure
your pdf file opens properly before uploading it.
• To include Java code in your submission document, copy all the text in your .java
file and then paste that text into your submission document. Use a monospaced
font (e.g.: Consolas , Courier ) for your code to maintain proper indentation.
Submitting code without proper indentation will result in marks being deducted.
It’s not enough that your code is indented in your text editor or in your integrated
programming environment – the indentation must show up that way in your
submission document as well. This sort of thing is part of learning to be an IT
professional.
• To include output from running your program in your submission document, the
preferred method is to copy and paste the text from your command prompt
window. Include the line with the “java” command you used to run your program.
 If the text shows up as a weird font or colour in your submission document,
first paste the text into a blank text editor document, then copy and paste from
there into your Microsoft Word submission document. This will remove all
formatting from the text.
 Use a monospaced font (e.g.: Consolas , Courier ) for output text in your
Word document. This will maintain alignment of your output.
• If at all possible, each line of code and each line of output should appear on a
single line in your submission document. Avoid allowing lines to “wrap” around
onto the next line. Use the tips provided in the “Avoiding Wrapped Lines” section
on the next page to accomplish this.
• To copy text from your command prompt window, try selecting the desired text
and then pressing either command-c (Mac) or control-c (Windows or Linux). If
you have issues, you can always use Google to see how to do this on your
specific type of computer.
• If a program involves graphical output (such as a JavaFX GUI program), capture
a screen shot of the output and include that as a picture / image in your
submission document.
 Make sure the image includes only the relevant portion of the screen (such
as a GUI window). Capturing an image of your entire computer screen often
makes the relevant portion too small to see, with tiny text that is difficult to read.
This makes your assignment submission difficult to grade.
• To capture a screen shot of a selected portion of your screen, try command-shift4 (Mac), WindowsKey-shift-s (Windows), or shift-PrtScrn (Linux).
Avoiding Wrapped Lines
In the following example, the lines of code containing the comment and the println
statement are both too long. The text is formatted so those lines can't fit all on one line
in this document. This obscures the indentation and makes the code more difficult to
read.
import java.util.Scanner;
public class WrapExample
{ public static void main(String[] args)
{ double pay = hours * wage;
int dollars = (int) pay;
int pennies = (int) ((pay - dollars) * 100.0);
// First all * and / operations are performed, left to
right, then all + and - operations, left to right
System.out.println("nThe pay for " + name + " is " +
dollars + " dollars and " + pennies + " cents.n");
} // end main method
} // end class
Below is the same code, but reformatted so none of the statements wrap around onto
the next line. Several changes were made:
1. The font size (in the Word document) is changed to a smaller size,
2. The tab size (in the Word document) is reduced
3. The longer statements and long comments are broken up onto multiple lines (do
this in your text editor, in the .java file), and
4. If need be, you can change the orientation of your Word document from Portrait
to Landscape
Now the indentation of the code within the main method is easier to see.
import java.util.Scanner;
public class WrapExample
{ public static void main(String[] args)
{ double pay = hours * wage;
int dollars = (int) pay;
int pennies = (int) ((pay - dollars) * 100.0);
// First all * and / operations are performed, left to right
 // Then all + and - operations, left to right
System.out.println("nThe pay for " + name + " is " + dollars
 + " dollars and " + pennies + " cents.n");
} // end main method
} // end class
Instructions – Part A – A Linked List of Numbers
The following files are provided for download earlier in this module:
• Node.java – A simple class for linked list nodes, where each node contains a
person’s name as a String.
• LinkedList.java – Contains some simple functionality for managing a linked
list of Node objects.
• ListTest.java – Performs simple testing for some of the functionality in the
LinkedList class.
All three of these classes will be updated as part of this assignment.
Update the Node class to store one int value in each Node instance, rather than a
name.
Update the LinkedList class to be consistent with your updated Node class.
Write a new testing class that does the following:
1. Create a new (empty) list using your updated LinkedList class.
2. Call the display method to display that empty list.
3. Use the insertInOrder() method to insert six randomly selected numbers between
1 and 49. Use the Random class to help generate each of those six numbers.
4. Call the display method to display your linked list of six numbers.
Include in Part A of your submission document:
• Complete code for Node.java, LinkedList.java, and your new testing class.
• Output from running your testing class twice.
Instructions – Part B – A Doubly Linked List of Numbers
1. Turn your updated list from Part A into a doubly linked list so Nodes are linked in
both directions, forward and backward. This entails:
• Adding a “previous” pointer to each Node object, along with getPrevious() and
setPrevious() methods in the Node class;
• Adding a “tail” pointer in the LinkedList class, along with a getTail() method;
and
• Updating whatever existing methods in the LinkedList class should be
changed so the values of “tail” and the “previous” pointers will be maintained
appropriately during all actions on the LinkedList.
2. Add a new instance variable called “size” to the LinkedList class. This variable must
keep track of the number of Nodes in the list at all times.
• Update the LinkedList constructor to set this variable appropriately when a
new list is created.
• Add a getSize() method that accesses the value of this variable. (Note: It
would not be appropriate to have a mutator method for this variable.)
• Update whatever existing methods in the LinkedList class should be changed
so the value of “size” will be maintained appropriately during all actions on the
LinkedList.
3. Add the following methods to the LinkedList class. Make sure all instance variables
in the Node and LinkedList classes are handled appropriately by these methods:
• insertAtHead(int num) – Inserts a new Node with the given number at the
beginning of the list. There is no need to check whether this operation keeps
the list in sorted order, nor is there any need to check whether this operation
results in duplicate numbers in the list.
• insertAtTail(int num) – Inserts a new Node with the given number at the end
of the list. There is no need to check whether this operation keeps the list in
sorted order, nor is there any need to check whether this operation results in
duplicate numbers in the list. (NOTE: This method should not include a loop.)
• removeAtHead() – removes the first Node in the list. Returns true if
successful, false otherwise (which should only happen when attempting to
removeAtHead() from an empty list).
• removeAtTail() – removes the last Node in the list. Returns true if successful,
false otherwise (which should only happen when attempting to removeAtTail()
from an empty list). (NOTE: This method should not include a loop.)
Update your testing class from Part A to test your updated Node and LinkedList classes
as follows:
1. Keep the four testing steps described in Part A (displaying the empty list, adding
and displaying six random numbers, etc.)
2. Use insertAtHead() to insert a randomly selected number between -100 and -50
at the head of the list. (The list should now contain seven nodes.)
3. Use insertAtTail() to insert a randomly selected number between 50 and 100 at
the tail of the list. (The list should now contain eight nodes.)
4. Call the display method to display your linked list of eight numbers.
5. Loop to call removeAtHead() three times.
6. Loop to call removeAtTail() three times.
7. Call the display method to display your linked list of what should now be two
numbers.
Include in Part B of your submission document:
• Complete code for your updated Node.java, LinkedList.java, and your updated
testing class.
• Output from running your updated testing class twice.
Instructions – Part C – An Updated LotteryTicket Class
Copy all the classes you wrote for the Module 2 Assignment to a new directory.
The LotteryTicket class you created for the Module 2 Assignment includes an array of
six randomly selected numbers between 1 and 49, without duplicates.
Update this LotteryTicket class to replace that array with a linked list of six randomly
selected numbers between 1 and 49, without duplicates. Use the Node and LinkedList
classes you updated for Part B to accomplish this.
This includes updating the following components of the LotteryTicket class:
• The constructor
• getNumbers()
• toString()
• chooseRandomNumbers()
• duplicateNumber(int i)
• countWinningNumbers(LinkedList winningNumbers)
The getWinningNumbers() method of the LotteryDraw class will also need to be
updated to return a reference to a LinkedList object rather than an array reference.
Test to make sure the LotteryDrawTest class you wrote for the Module 2 Assignment
still works with your updated LotteryTicket and LotteryDraw classes.
Include in Part C of your submission document:
• Complete code for your updated LotteryTicket and LotteryDraw classes.
• Output from running LotteryDrawTest twice.
Submission Instructions
Include the following in your submission document:
Your name, student number, CS1083, Module 9 Assignment, and the date.
Complete source code and testing output for each of Sections A, B, and C as
described above.
D2L DROPBOX SUBMISSION INSTRUCTIONS
Upload only one pdf file to D2L. Do not upload separate files (such as your .java
files) as they will be ignored. Upload your submission document as follows:
1. In the top-navigation bar on the course screen, select 'Assessments' and then
'Assignments'.
2. Select the assignment title and follow the instructions to upload your submission
document.
請加QQ:99515681  郵箱:99515681@qq.com   WX:codehelp 










 

標簽:

掃一掃在手機打開當前頁
  • 上一篇:代寫代做Project 3 - CanvasList CS 251
  • 下一篇:代做CS252編程、代寫C++設計程序
  • 無相關信息
    昆明生活資訊

    昆明圖文信息
    蝴蝶泉(4A)-大理旅游
    蝴蝶泉(4A)-大理旅游
    油炸竹蟲
    油炸竹蟲
    酸筍煮魚(雞)
    酸筍煮魚(雞)
    竹筒飯
    竹筒飯
    香茅草烤魚
    香茅草烤魚
    檸檬烤魚
    檸檬烤魚
    昆明西山國家級風景名勝區
    昆明西山國家級風景名勝區
    昆明旅游索道攻略
    昆明旅游索道攻略
  • 短信驗證碼平臺 理財 WPS下載

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

    Copyright © 2025 kmw.cc Inc. All Rights Reserved. 昆明網 版權所有
    ICP備06013414號-3 公安備 42010502001045

    久久久久久精品无码人妻_青春草无码精品视频在线观_无码精品国产VA在线观看_国产色无码专区在线观看

    小明看看成人免费视频| 欧美久久在线观看| 久久成人福利视频| 少妇黄色一级片| 成人免费在线视频播放| 日韩免费高清在线| 99中文字幕在线观看| 欧美精品无码一区二区三区| 蜜桃网站在线观看| 孩娇小videos精品| 激情综合在线观看| bt天堂新版中文在线地址| 四季av一区二区三区| 亚洲熟妇av一区二区三区| 国产成人免费高清视频| 亚洲涩涩在线观看| 情侣黄网站免费看| 日韩一级性生活片| 强开小嫩苞一区二区三区网站| 凹凸日日摸日日碰夜夜爽1| 日本a级片在线播放| 五月天视频在线观看| 免费裸体美女网站| 国产免费一区二区三区视频| 日本特黄在线观看| 深夜黄色小视频| 欧美黑人又粗又大又爽免费| 国内精品视频一区二区三区| 日本美女爱爱视频| 99re99热| 波多野结衣网页| 午夜激情影院在线观看| 欧美一级特黄a| 日韩中文字幕组| 无码人妻精品一区二区三区在线| 50度灰在线观看| 色婷婷777777仙踪林| 四虎免费在线观看视频| 爽爽爽在线观看| www.51色.com| 亚洲免费av一区| 天天干天天草天天| 一级在线免费视频| 亚洲少妇第一页| 91色国产在线| 99视频免费播放| 亚洲 欧美 日韩系列| 三年中国国语在线播放免费| 久久久久免费精品| 天堂在线资源视频| 中文字幕 日韩 欧美| 亚洲美女爱爱视频| www.成人黄色| 超碰在线免费观看97| 91麻豆天美传媒在线| 免费的av在线| www插插插无码免费视频网站| 久久久国内精品| 美脚丝袜脚交一区二区| 尤物av无码色av无码| 欧美a在线视频| 日韩一级片播放| 欧美美女一级片| 好色先生视频污| www.九色.com| 丰满爆乳一区二区三区| 日韩在线第三页| 国产3p在线播放| 裸体大乳女做爰69| 国产一区二区三区小说| 免费看一级大黄情大片| 国产一区亚洲二区三区| 国产免费又粗又猛又爽| 国产乱女淫av麻豆国产| 91视频成人免费| 熟女少妇在线视频播放| a在线观看免费视频| 国产奶头好大揉着好爽视频| 国产黄色片免费在线观看| 国产成人久久777777| 中文字幕亚洲乱码| 中国女人做爰视频| 99精品视频在线看| 97人人爽人人| 久草视频国产在线| 天天干天天草天天| 久久综合亚洲精品| 日韩av播放器| 1314成人网| 久久黄色片视频| 天天干天天av| 色欲色香天天天综合网www| 中文字幕国内自拍| 97在线免费视频观看| 国产性xxxx18免费观看视频| 波多野结衣免费观看| 欧美色图色综合| 三级黄色片播放| 欧美精品99久久| 欧美日韩在线免费观看视频| 欧美日韩一道本| 91香蕉国产线在线观看| 日韩avxxx| 三年中国中文在线观看免费播放| 无码人妻丰满熟妇区96| 亚洲制服中文字幕| 免费国产成人av| 欧洲精品在线播放| 日韩在线一区视频| 成人久久久久久久久| 日本美女爱爱视频| 国产91色在线观看| 麻豆tv在线播放| 在线免费黄色小视频| 男人的天堂日韩| 亚洲国产成人精品无码区99| 天天综合成人网| 欧美少妇性生活视频| www.九色.com| 最新视频 - x88av| 香蕉视频禁止18| 久久精品香蕉视频| 亚洲精品蜜桃久久久久久| 特黄视频免费观看| 中文字幕欧美人妻精品一区| 成人午夜视频在线观看免费| 懂色av一区二区三区四区五区| 青青草精品视频在线观看| 极品粉嫩国产18尤物| 浴室偷拍美女洗澡456在线| 艹b视频在线观看| 毛片av免费在线观看| 亚洲中文字幕无码av永久| 特大黑人娇小亚洲女mp4| 中文字幕资源在线观看| 欧美三级理论片| 日韩 欧美 高清| 精品视频免费在线播放| 97免费视频观看| 欧美日韩午夜爽爽| 艳母动漫在线观看| 精品国产乱码久久久久久1区二区 91网址在线观看精品 | 日韩免费视频播放| 国产片侵犯亲女视频播放| 91丝袜超薄交口足| gogogo高清免费观看在线视频| 亚洲乱码国产一区三区| 欧美丰满熟妇bbbbbb百度| 日韩视频免费播放| 成人免费在线网| 国产美女主播在线| 欧美日韩午夜爽爽| 欧洲精品视频在线| 先锋影音男人资源| 红桃一区二区三区| 久久久99精品视频| 国产爆乳无码一区二区麻豆 | 18禁网站免费无遮挡无码中文| 中文字幕第一页亚洲| 日本在线视频www色| 欧美精品久久96人妻无码| 四虎4hu永久免费入口| 三级在线免费观看| 欧美视频在线第一页| 97碰在线视频| 欧美日韩性生活片| 国产麻花豆剧传媒精品mv在线| 国产中文字幕视频在线观看| 亚欧无线一线二线三线区别| 99视频在线免费播放| 久久婷婷五月综合色国产香蕉| av动漫在线观看| 国产自偷自偷免费一区 | 99热这里只有精品7| 欧美交换配乱吟粗大25p| 搞av.com| aaaaaa亚洲| 高潮一区二区三区| 国产树林野战在线播放| www.成年人视频| 久久无码高潮喷水| 日本xxxx黄色| av在线网站免费观看| 黄色一级片国产| 日韩国产欧美亚洲| 国产福利影院在线观看| 99日在线视频| 精品一二三四五区| 日日碰狠狠躁久久躁婷婷| 在线观看国产一级片| 99热都是精品| 久久9精品区-无套内射无码| 欧美成人三级在线播放| 天天想你在线观看完整版电影免费 | 中文字幕超清在线免费观看| 97中文字幕在线| 色一情一乱一伦一区二区三区日本| 天天操精品视频| 欧美精品一区免费| 亚洲天堂av一区二区|