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

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

代寫CSE 231、代做Python設計程序

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



CSE 231 Spring 2024
Computer Project 05
1. Assignment Overview (learning objectives)
In this assignment, you will practice with files, lists and error-handling using exceptions. You are only allowed
to use Lists and tuples. Any use of other advanced data structures (e.g., Dictionaries, Classes, etc.) will result in
a zero on the project.
2. Important Note about submission
3. Assignment Deliverable
The deliverable for this assignment is the following file:
proj05.py – the source code for your Python program
Be sure to use the specified file name and to submit it for grading via Codio before the project deadline.
4. Assignment Background
Yu-Gi-Oh! Trading Card Game which is based on the manga series of the
same name and anime spin-off series Yu-Gi-Oh! Duel Monsters both
created by Kazuki Takahashi and were released in 1996 and 2000. As the
moment of writing this project, this franchise is currently celebrating its 25th
anniversary. This franchise has developed thousands of iconic cards like:
Dark Magician, Blue-Eyes White Dragon, Elemental Hero Neos, Stardust
Dragon, and much more.
As beloved as this series is with its strategic focus on monster cards, spell,
and trap cards, it is not a hobby for everybody. Collecting some of these
cards can be expensive, especially when they are popular in the competitive
circuit. This project will read a dataset of these cards and show their prices
on the market and how much does it cost to build a deck of these cards when
bought in said market. The files used in this project were adapted from the
following sources:
1) Card data: https://www.kaggle.com/datasets/ioexception/yugioh-cards/code
2) Decklists: https://ygoprodeck.com/
This assignment is worth 50 points (5.0% of course grade), and must be completed before 11:59 PM
EST on Tuesday, March 5th.
After the due date, your score will be deducted by 10% for every 5 hours late or a fraction of it. No
submissions will be accepted after 24 hours from the due date. The penalty will be applied on the
full project score.
The project will be automatically submitted by the due date (03/05). If you want to keep working on it
after the deadline with penalty, you must manually click on “Mark as uncompleted”, acknowledge the
penalty message and manually click on “Mark as completed” when done.
CSE 231 Spring 2024
These files contain the following information of each card:
a) card_id (str): Unique card identifier
b) card_name (str): Card name
c) card_type (str): “Spell”, “Trap”, and various type of “Monster” cards
d) card_description (str): Card summoning requirements and or card effects
e) card_race (str): Card species. For example: “Spellcaster”, “Dragon”, or “Counter Trap”
f) card_archetype (str): Name of group of cards that support specific characters: “Dark
Magician”
g) card_price (float): TCG player price for the card in the second market.
5. Assignment Specifications
1. You must implement the following functions:
a) open_file (prompt_str) ---- file pointer
This function repeatedly prompts the user for a filename (using the prompt string: prompt_str) until
the file is opened successfully. An error message should be shown if the file cannot be opened (check
the starter code or the strings.txt file for the appropriate strings). It returns a file pointer.
Use try-except to determine if the file can be opened. When opening the file, you need to use
encoding=" utf-8".
fp = open(filename, "r", encoding = " utf-8")
b) read_card_data(fp) ---- List of tuples
This function is designed to parse a file containing the dataset of Yu-Gi-Oh trading cards. It takes a file
pointer object (fp) as its parameter, which is returned by the open_file function. The function
returns a list of tuples, where each tuple represents a card in the dataset.
Each tuple consists of the following columns: id, name (limited to the first 45 characters), type,
description, race, archetype, and the card's TCGPlayer price. To understand the dataset's format and
identify the column indices we are interested in, it is recommended to open the CSV files in Excel or
any text editor.
The price is converted to a float within the tuple. After assembling the list of tuples, it is sorted in
ascending order based on price first and then by name.
c) search_cards(card_data, query, category_index) ---- List of tuples
This function returns a list of cards that contain the provided query string in the given category index. It
takes as its parameters: card_data (a list of cards like the list returned by read_card_data
function), query (a string to search in a selected category), and category_index (the index of the
category to search in the CATEGORIES list provided in the starter code). The returned list should be
sorted in ascending order by price first and then by name.
For example:
query = "Dark Magician"
category_index = 1 # Name
result = [(xxxxx, "Dark Magician", ...), (xxxxx, "Dark Magician Girl", ...), ...]
CSE 231 Spring 2024
d) read_decklist(fp, card_data) ---- List of tuples
This function creates a list of cards present in the current deck list (a YDK file). It takes as its
parameters: a file pointer object (fp) to a YDK file and a card_data (a list of cards like the list
returned by read_card_data function). The YDK file contains the ID of cards in a deck where
each line in the file is a card ID. The function reads the IDs from the file and searches for all the cards
by their “id” column.
The returned list should be sorted in ascending order by price first and then by name.
e) compute_stats(card_data) List_tuples,float,List_tuples,float,List_tuples,
float
This function takes as its parameter a card_data (a list of cards like the list returned by
read_card_data function). It finds the minimum price, maximum price, and median price for all
the cards in card_data. It also finds the list of cards that have the same value as the min, max, and
median. Then, it returns the list of cards with the min price, the minimum price, the list of cards with the
max price, the maximum price, the list of cards with the median price, and the median price.
All lists should be sorted by name.
f) display_data(card_data)
This function takes as its parameter a card_data (a list of cards like the list returned by
read_card_data function). It prints the contents of each card tuple in the card_data list. Then,
it prints the total price. The table should be formatted properly. There are 5 columns in the table. First, a
header line should be displayed:
i. the string 'Name': in a field width of 50
ii. the string 'Type': in a field width of 30
iii. the string 'Race': in a field width of 20
iv. the string 'Archetype': in a field width of 40
v. the string 'TCGPlayer': in a field width of 12
Then, the cards are displayed using the following formatting:
i. Name: in a field width of 50
ii. Type: in a field width of 30
iii. Race: in a field width of 20
iv. Archetype: in a field width of 40
v. Price: in a field width of 12 with precision 2 and the comma for the thousand
Finally, a line that shows the total price which is the sum of all the card prices should be displayed using
the following formatting:
i. the string 'Total': in a field width of 50
ii. an empty string '': in a field width of 30
iii. an empty string '': in a field width of 20
iv. an empty string '': in a field width of 40
v. Total: in a field width of 12 with precision 2 and the comma for the thousand
g) display_stats(min_cards, min_price, max_cards, max_price,
median_cards, median_price)
This function prints the output from compute_stats() function. First, the minimum price is
displayed with precision 2 and comma for the thousand. It is followed by all the card names that have a
price the same as the minimum price. The function will do the same for the maximum and median price
and data.
CSE 231 Spring 2024
h) main(): This function is the starting point of the program. The program prompts the user for an option
until the user decides to stop the program:
i. Prompt the card data filename (use the correct prompt from the starter code).
ii. Read the card data file and get the list of categories and the list of card tuples.
iii. Close the file.
iv. Prompt an option
v. Option 1 (Show all cards): This option shows details about each card in the dataset. It
will find and display the number of cards in the data set. Then, use
display_data()to show information of only the cheapest 50 cards in the dataset.
Then, find and print all the cards that have the maximum price, minimum price, and the
median price using the display_stats() function.
vi. Option 2 (Search for cards): Prompt for a query string pertaining to a specific column
in the card dataset. Re-prompt for category until the user enters a valid category (a
category that is in the CATEGORY list). You should convert the input category to
lowercase since the CATEGORY list items are all lowercase strings.
Get all cards that satisfy the provided query. Find the maximum, minimum, and median
values for all resulting cards in the search. If there are any cards that satisfies the query,
display the number of cards in the results, then output the card information and the results
like option 1. Otherwise, print that there are no cards in the category.
vii. Option 3 (Search decklist): Prompt for a decklist filename and build a list of cards that
have the same “card id” in the file. Show the card information; find the maximum,
minimum, and median prices and display them.
viii. Option 4: Stop the program.
ix. If the user does not enter any of these options, the program needs to display an error
message and prompt again until a valid option is selected.
6. Assignment Notes and Hints
1. The coding standard for CSE 231 is posted on the course website:
http://www.cse.msu.edu/~cse231/General/coding.standard.html
Items **9 of the Coding Standard will be enforced for this project.
2. The program will produce reasonable and readable output, with appropriate labels for all values
displayed.
3. Be sure to prompt the user for the inputs in the correct order. And, your program cannot prompt the user
for any supplementary inputs.
4. We provide a proj05.py program for you to start with.
5. You are not allowed to use advanced data structures such as dictionaries, classes, etc.
6. If you “hard code” answers, you will receive a grade of zero for the whole project. An example of hard
coding is to simply print the correct highest scores of a file rather than having the program find it in the
file and then print it.
7. Suggested Procedures
• Solve the problem using pencil and paper first. You cannot write a program until you have figured out
how to solve the problem. This first step can be done collaboratively with another student. However,
once the discussion turns to Python specifics and the subsequent writing of Python statements, you must
work on your own.
CSE 231 Spring 2024
• Cycle through the following steps to incrementally develop your program:
o Edit your program to add new capabilities.
o Run the program on Spyder and fix any errors.
o Use the Codio system to submit the current version of your program.
• Be sure to use the Codio system to submit the final version of your program.
• Be sure to log out when you leave the room, if you’re working in a public lab.
The last version of your solution is the program which will be graded by your TA. You should use the Codio
system to back up your partial solutions, especially if you are working close to the project deadline. That is the
easiest way to ensure that you won’t lose significant portions of your work if your machine fails or there are
other last-minute problems.
8. Grading Rubric
Computer Project #05 Scoring Summary
General Requirements
______ (4 pts) Coding Standard **8
 (descriptive comments, function header, etc...)
Implementation:
____ (2 pts) Pass test1
____ (2 pts) Pass test2
____ (2 pts) Pass test3
____ (2 pts) Pass test4
____ (2 pts) Pass test5
____ (2 pts) Pass test6
____ (12 pts) Pass hidden tests (4 pts each)
____ (14 pts) All functions work as specified.
(2 pt) open_file (Manual Grading)
-1 point if No try/except
-1 point if No while loop
 (2 pt) read_card_data
(2 pt) read_decklist
(2 pt) search_cards
(2 pt) compute_stats
(2 pt) display_data (Manual Grading)
(2 pt) display_stats (Manual Grading)
____ (8 pts) Pass All hidden functions tests.
 (2 pt) read_card_data
(2 pt) read_decklist
(2 pt) search_cards
(2 pt) compute_stats
Note:
• hard coding an answer earns zero points for the whole project.
• -10 points for not putting all your user interaction in your main().
• Use of any advanced data structures (such as lists, sets, dictionaries, classes,
etc.) earns zero points for the whole project.
CSE 231 Spring 2024
9. Test Cases
9.1 Function Unit Tests
Check the test files in the Project05 starter package. When you run one test file as you normally run a python
file in PyCharm. if an assertion error is generated, it means you failed the test. You can look at the test case .py
files to see the details for the tests.
9.2 Input/Output Tests
We provide the .txt files with all the test files (inputX.txt and output.txt where X is the test number).
If you fail a test, use diffchecker.com to check the difference between your output and the instructor output.
請加QQ:99515681  郵箱:99515681@qq.com   WX:codehelp 









 

掃一掃在手機打開當前頁
  • 上一篇:CS 2410代做、代寫C/C++語言程序
  • 下一篇:代寫DTS203TC、C++,Java程序語言代做
  • 無相關信息
    合肥生活資訊

    合肥圖文信息
    急尋熱仿真分析?代做熱仿真服務+熱設計優化
    急尋熱仿真分析?代做熱仿真服務+熱設計優化
    出評 開團工具
    出評 開團工具
    挖掘機濾芯提升發動機性能
    挖掘機濾芯提升發動機性能
    海信羅馬假日洗衣機亮相AWE  復古美學與現代科技完美結合
    海信羅馬假日洗衣機亮相AWE 復古美學與現代
    合肥機場巴士4號線
    合肥機場巴士4號線
    合肥機場巴士3號線
    合肥機場巴士3號線
    合肥機場巴士2號線
    合肥機場巴士2號線
    合肥機場巴士1號線
    合肥機場巴士1號線
  • 短信驗證碼 豆包 幣安下載 AI生圖 目錄網

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

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

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

          9000px;">

                免费观看久久久4p| 制服.丝袜.亚洲.另类.中文| 欧洲一区二区三区免费视频| 国产精品午夜免费| 91黄色免费版| 天天影视网天天综合色在线播放| 欧美日韩国产综合一区二区| 日韩av电影天堂| xfplay精品久久| 91视频观看免费| 免费成人在线网站| 18成人在线观看| 欧美一级午夜免费电影| 国产成人精品免费在线| 亚洲精品一二三| 欧美成人r级一区二区三区| 成人av资源站| 免费成人在线影院| 亚洲人成小说网站色在线 | 日本亚洲天堂网| 欧美激情一二三区| 4438x成人网最大色成网站| 成人一区在线看| 蜜臀av在线播放一区二区三区| 中文字幕免费不卡在线| 69堂成人精品免费视频| 99精品视频中文字幕| 狠狠色狠狠色综合系列| 亚洲成人激情综合网| 亚洲欧美综合色| 国产日韩av一区| 精品久久五月天| 91精品国产综合久久久蜜臀图片| 9久草视频在线视频精品| 狠狠狠色丁香婷婷综合久久五月| 亚洲www啪成人一区二区麻豆 | 欧美成人免费网站| 91.成人天堂一区| 欧美午夜精品免费| 在线免费观看日韩欧美| 99国产精品久久| 9i在线看片成人免费| 国产成人午夜高潮毛片| 国产精品一区不卡| 国产白丝网站精品污在线入口| 精品一区二区在线免费观看| 肉丝袜脚交视频一区二区| 亚洲国产另类精品专区| 亚洲高清视频的网址| 亚洲国产中文字幕| 亚洲成人黄色影院| 日本美女一区二区三区| 婷婷六月综合网| 亚洲一卡二卡三卡四卡| 五月综合激情婷婷六月色窝| 亚洲精品视频在线观看网站| 一区二区三区.www| 亚洲成a人片综合在线| 日韩高清一级片| 日韩电影在线观看一区| 精东粉嫩av免费一区二区三区| 国产在线播精品第三| 国产一区91精品张津瑜| 不卡视频一二三| 欧美日韩中文精品| 日韩欧美在线综合网| 久久亚洲一级片| 亚洲视频在线观看一区| 香港成人在线视频| 久久99久久99| 99久久婷婷国产综合精品电影| 在线精品视频免费播放| 欧美成人在线直播| 国产精品成人一区二区三区夜夜夜| 亚洲精品国久久99热| 日韩精品色哟哟| 亚洲一区在线观看免费 | 国产精品久久影院| 香蕉成人伊视频在线观看| 九色|91porny| 91美女蜜桃在线| 日韩女优制服丝袜电影| 国产精品国产三级国产aⅴ中文| 亚洲精品视频在线观看免费| 麻豆成人免费电影| 91在线观看污| 91精品中文字幕一区二区三区| 久久久99久久精品欧美| 亚洲小少妇裸体bbw| 国产精品一区在线观看乱码| 色av一区二区| 久久亚区不卡日本| 亚洲成a人片综合在线| 国产一区二区三区日韩| 色老综合老女人久久久| 精品国免费一区二区三区| 亚洲已满18点击进入久久| 精品一区二区三区欧美| 欧美日韩国产高清一区二区| 国产精品情趣视频| 国产一区二区三区精品欧美日韩一区二区三区| 91亚洲国产成人精品一区二区三 | 欧美性大战久久久| 欧美激情一区在线| 青青草伊人久久| 欧美三级日本三级少妇99| 欧美国产成人精品| 国内外精品视频| 精品噜噜噜噜久久久久久久久试看| 亚洲福利一二三区| aaa欧美大片| 国产精品乱人伦中文| 另类调教123区| 欧美一区二区三区视频免费播放| 最新久久zyz资源站| 国产精品1区二区.| ww亚洲ww在线观看国产| 午夜精品一区在线观看| 欧美视频完全免费看| 国产精品欧美一区喷水| 成人精品视频一区| 中文字幕av一区二区三区| 久99久精品视频免费观看| 日韩欧美一级二级三级| 免费的成人av| 精品久久国产字幕高潮| 美国十次了思思久久精品导航| 欧美二区三区91| 免播放器亚洲一区| 欧美不卡激情三级在线观看| 蜜臀av性久久久久蜜臀aⅴ四虎| 欧美日韩黄色影视| 奇米影视7777精品一区二区| 91精品国产综合久久福利软件| 五月婷婷激情综合| 精品毛片乱码1区2区3区| 美女精品自拍一二三四| 久久久久久久久久久99999| 国v精品久久久网| 亚洲精品视频自拍| 欧美人牲a欧美精品| 日韩精品欧美精品| 国产亚洲欧洲997久久综合 | 99久久99久久精品免费观看| 欧美麻豆精品久久久久久| 亚洲欧美日韩久久精品| 欧美日韩精品欧美日韩精品一综合| 偷拍日韩校园综合在线| 欧美videofree性高清杂交| 国产精一品亚洲二区在线视频| 国产精品久久久久aaaa樱花| 在线亚洲欧美专区二区| 蜜桃视频在线一区| 国产精品久久久久aaaa| 91精品国产一区二区三区| 国产一区亚洲一区| 亚洲精品欧美综合四区| 日韩视频免费观看高清完整版在线观看 | 亚洲第一久久影院| 久久久久久免费网| 色婷婷av一区二区三区软件| 奇米一区二区三区| 亚洲欧美在线观看| 欧美mv日韩mv国产网站app| 成人永久看片免费视频天堂| 香蕉乱码成人久久天堂爱免费| 2021中文字幕一区亚洲| 欧洲人成人精品| 丁香婷婷深情五月亚洲| 日韩电影一区二区三区| 18成人在线视频| 精品国产精品网麻豆系列| 在线区一区二视频| 粉嫩绯色av一区二区在线观看| 日韩不卡免费视频| 亚洲三级免费观看| ww久久中文字幕| 91精品国产综合久久香蕉麻豆| 成人自拍视频在线观看| 麻豆免费精品视频| 日韩电影一二三区| 一区二区三区色| 亚洲男人电影天堂| 欧美国产精品劲爆| 久久久久久久久久久久久久久99| 欧美三级在线看| 在线免费观看日本一区| 成人av免费在线播放| 国产成人日日夜夜| 日本中文字幕一区| 手机精品视频在线观看| 亚洲一区在线观看视频| 中文字幕日韩欧美一区二区三区| 久久精品一区蜜桃臀影院| 精品国产一区二区三区不卡| 欧美午夜影院一区| 欧美男生操女生| 日韩欧美中文字幕公布| 精品国产青草久久久久福利| 欧美tickling网站挠脚心|