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

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

INT5051代做、代寫Python編程設(shè)計
INT5051代做、代寫Python編程設(shè)計

時間:2025-03-07  來源:合肥網(wǎng)hfw.cc  作者:hfw.cc 我要糾錯



Assignment 2
INT2067/INT5051 Introduction to Programming and Problem Solving
2024-2025 Semester 2
Due Date: March 16, 2025 (Sunday)
1 Introduction
In this assignment, you need to implement a text-based game based on the riddle about a 
farmer who needs to cross a river with a fox, a goose, and a sack of corn.
2 Riddle
A farmer with a fox, a goose, and a sack of corn needs to cross a river. The farmer has a
rowboat, but there is room for only the farmer and one of her three items. Unfortunately, 
both the fox and the goose are hungry. The fox cannot be left alone with the goose, or the 
fox will eat the goose. Likewise, the goose cannot be left alone with the sack of corn, or 
the goose will eat the corn. How does the farmer get everything across the river?
3 Game
In your text-based game, the farmer can move at most one item to the other shore each 
time. You should ask the user to enter a command to determine what item the farmer 
wants to take at each turn. The game ends when the user quits the game or when the user 
has succeeded or failed.
4 Basic Design
You may follow the following basic flow in your program:
• Show item locations.
• Repeat:
1) Ask for the next command.
2) Update item locations if necessary.
3) Show item locations.
4) Exit the loop if the game has succeeded or failed.
You may need to add other steps and/or flows to fulfill all the requirements.
5 Requirement (70%)
Your program should do the following:
• [5%] Print the goal of the game at the start.
• [10%] Ask the user to enter a command at each turn, and continue until the user 
requests to quit or the goal has succeeded or failed.
• [10%] Show the location of the boat and the three items (fox, goose, corn) clearly 
at the start of the game and after each turn. You may follow the output in the 
sample sections.
• Accept the following five one-character strings as valid commands: f, g, c, m or 
q. After receiving a valid command, the game should:
o [10%] f, g or c: move the fox, goose, or corn, if available, to the opposite 
shore along with the boat.
o [5%] m: move the boat to the opposite shore without any item.
o [5%] q: quite the game.
• [10%] Check whether the requested item is on the same shore as the boat when 
the game receives the command f, g or c. If not, it should prompt an error and 
allow the user to enter a command again.
• [10%] Check whether the game has succeeded or failed after each turn. The game 
has succeeded if all items have been moved to the far shore. The game has failed 
if the fox has eaten the goose or the goose has eaten the corn. When the game has 
succeeded, it should congratulate the user. When the game has failed, it should 
tell the user why.
• [5%] Show an error if the user has entered an unrecognized command character 
(i.e., a string other than ‘f’, ‘g’, ‘c’, ‘m’ or ‘q’).
6 Program Design and User Interface (30%)
• [10%] You should break down your program into functions with reasonable 
length.
• [10%] You should use functions and/or data structures to reduce redundancy.
• [10%] The output should be neat and the required information should be shown 
clearly. The text in the output should be correct and contains no spelling mistakes.
7 Submission Requirements
Your Python file should be named as assignment2.py. Submit only the Python file 
assignment2.py through Moodle. Failure to submit the file properly will result in a 
penalty of 5 to 10 marks.
See Moodle for the exact time of the deadline for submission. Late submission is will 
induce penalty.
8 Hints
Please check the discussions forum on Moodle regularly for any hints.
9 Plagiarism Policy
The assignment should be done only by yourself. Every line of code should be written by 
you. The use of any artificial intelligence (AI) tools is NOT allowed in this assignment. 
Discussions on the assignment should be kept at a high-level only. You are suggested to 
refer your classmates to the relevant notes or lab exercises if you want to help them.
You need to put down a declaration for having not used AI tools as comment at the 
beginning of your program file. For example, your declaration may look like this:
# Declaration: this code is my own individual and original work without AI assistant.
If you have used AI tools or consulted the assignment with anyone, you should provide 
an acknowledgment as comment at the beginning of your program file. Give the names 
of all classmates that you have turned to. For example, your acknowledgement may look 
like:
# Acknowledgement: I have asked Thomas, Gordon, and Emily for help.
# Acknowledgement: I have used AI tools (such as ChatGPT, gpt4o via POE, etc.) in 
working on this assignment.
If plagiarism is found, both the copier and originator will get zero mark for the assignment.
Repeat offenders may result in a deduction of the course grade.
10 Sample Input & Output 1
Welcome
You have to bring the fox, the goose, and the corn across the river.
------------------------
 Boat
------------------------
 Fox Goose Corn 
You are now at the near shore, what do you want to take? g
 Goose
------------------------
 Boat
------------------------
 Fox Corn 
You are now at the far shore, what do you want to take? m
 Goose
------------------------
 Boat
------------------------
 Fox Corn 
You are now at the near shore, what do you want to take? f
 Fox Goose
------------------------
 Boat
------------------------
 Corn 
You are now at the far shore, what do you want to take? g
 Fox
------------------------
 Boat
------------------------
 Goose Corn 
You are now at the near shore, what do you want to take? c
 Fox Corn 
------------------------
 Boat
------------------------
 Goose
You are now at the far shore, what do you want to take? m
 Fox Corn 
------------------------
 Boat
------------------------
 Goose
You are now at the near shore, what do you want to take? g
 Fox Goose Corn 
------------------------
 Boat
------------------------
Congratulations!
You have brought all items across the river.
11 Sample Input & Output 2
Welcome
You have to bring the fox, the goose, and the corn across the river.
------------------------
 Boat
------------------------
 Fox Goose Corn 
You are now at the near shore, what do you want to take? goose
You have entered an invalid command.
------------------------
 Boat
------------------------
 Fox Goose Corn 
You are now at the near shore, what do you want to take? f
 Fox
------------------------
 Boat
------------------------
 Goose Corn 
You have failed.
The goose has eaten the corn.
12 Reference
V. Anton Sprual. Think Like a Programmer: An Introduction to Creative Problem Solving. 
No Starch Press, San Francisco, 2012.

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

掃一掃在手機打開當(dāng)前頁
  • 上一篇:EEE6207代做、代寫C++程序設(shè)計
  • 下一篇:代寫MS6711、代做Python語言程序
  • 無相關(guān)信息
    合肥生活資訊

    合肥圖文信息
    流體仿真外包多少錢_專業(yè)CFD分析代做_友商科技CAE仿真
    流體仿真外包多少錢_專業(yè)CFD分析代做_友商科
    CAE仿真分析代做公司 CFD流體仿真服務(wù) 管路流場仿真外包
    CAE仿真分析代做公司 CFD流體仿真服務(wù) 管路
    流體CFD仿真分析_代做咨詢服務(wù)_Fluent 仿真技術(shù)服務(wù)
    流體CFD仿真分析_代做咨詢服務(wù)_Fluent 仿真
    結(jié)構(gòu)仿真分析服務(wù)_CAE代做咨詢外包_剛強度疲勞振動
    結(jié)構(gòu)仿真分析服務(wù)_CAE代做咨詢外包_剛強度疲
    流體cfd仿真分析服務(wù) 7類仿真分析代做服務(wù)40個行業(yè)
    流體cfd仿真分析服務(wù) 7類仿真分析代做服務(wù)4
    超全面的拼多多電商運營技巧,多多開團助手,多多出評軟件徽y1698861
    超全面的拼多多電商運營技巧,多多開團助手
    CAE有限元仿真分析團隊,2026仿真代做咨詢服務(wù)平臺
    CAE有限元仿真分析團隊,2026仿真代做咨詢服
    釘釘簽到打卡位置修改神器,2026怎么修改定位在范圍內(nèi)
    釘釘簽到打卡位置修改神器,2026怎么修改定
  • 短信驗證碼 豆包網(wǎng)頁版入口 破天一劍 目錄網(wǎng) 排行網(wǎng)

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

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

    国产人妻人伦精品_欧美一区二区三区图_亚洲欧洲久久_日韩美女av在线免费观看
    亚洲a级在线播放观看| 精品国产电影| 精品久久久av| 日韩中文在线字幕| 国产精品有限公司| 欧美精品日韩三级| 人妻精品无码一区二区三区| 久久这里只有精品8| 亚洲中文字幕无码不卡电影 | 午夜精品在线观看| 北条麻妃av高潮尖叫在线观看| 久久综合久久88| 精品欧美一区二区三区久久久 | 国产精品爽爽爽爽爽爽在线观看 | 国产精品久久久久久久天堂第1集| 日韩免费一区二区三区| 国产高清不卡无码视频| 无码人妻丰满熟妇区96| 97久久精品在线| 亚洲一区二区在线| 91av在线网站| 日本午夜精品一区二区三区| 国产盗摄视频在线观看| 日韩成人在线资源| 日韩中文字幕精品视频| 日韩av免费在线看| 久草免费福利在线| 日韩人妻精品一区二区三区| 久久国产精品免费一区| 亚洲一区二区三区色| 97免费中文视频在线观看| 亚洲伊人成综合成人网| 91精品国产99久久久久久| 亚洲wwwav| 久久99精品久久久久久秒播放器| 日本伊人精品一区二区三区介绍| 国产精品影片在线观看| 中文字幕一区二区三区四区五区人 | 国产精品成人国产乱一区| 欧美一乱一性一交一视频| 国产爆乳无码一区二区麻豆| 热久久这里只有精品| 日日骚久久av| 亚洲精品成人自拍| 久久久久久久久久久久av| 婷婷精品国产一区二区三区日韩| 国产精品91一区| 日韩精品―中文字幕| 日韩在线视频免费观看| 日本www在线视频| 久久综合九九| 美女啪啪无遮挡免费久久网站| 久久五月天色综合| 久久精品国产久精国产一老狼| 久久久久国产精品熟女影院| 久久国产精品久久精品国产| 国产精品羞羞答答| 久久99精品久久久久久久青青日本| 久久久av网站| 国产一区二区在线免费| 亚洲a在线播放| 国产精品久久久久久久小唯西川 | 国产日本一区二区三区| 久久好看免费视频| 久热免费在线观看| 日韩精品一区二区三区电影 | 欧美激情中文字幕乱码免费| 99精品人妻少妇一区二区| 日韩av免费看| 欧美激情区在线播放| 久久亚洲精品欧美| 欧美不卡在线播放| 亚洲第一页在线视频| 国产精品欧美一区二区| 97免费中文视频在线观看| 日本精品一区二区三区在线| 国产精品激情av电影在线观看| 国产在线精品播放| 亚洲高清123| 国产精品美女久久久久av福利| 成人美女免费网站视频| 国产av熟女一区二区三区| 国产一级片91| 日本人妻伦在线中文字幕| 九九热精品视频国产| 久久超碰亚洲| 国产精品一区二区免费在线观看 | 欧美激情在线有限公司| 色婷婷av一区二区三区久久| 国内精品国产三级国产99| 午夜精品久久久内射近拍高清| 欧美亚洲视频一区| 中文字幕一区二区三区四区五区人 | 日韩成人av电影在线| 色综合天天狠天天透天天伊人| 久精品国产欧美| 国产精品12345| 免费观看精品视频| 欧美影院久久久| 性色av香蕉一区二区| 久久久久国产精品免费| 国产精品入口夜色视频大尺度| 8090成年在线看片午夜| 国产精品自拍片| 国产一级黄色录像片| 狠狠色狠狠色综合人人| 日本免费在线精品| 日韩中文在线字幕| 色婷婷精品国产一区二区三区| 亚洲视频电影| 伊人久久大香线蕉综合75| 国产精品成人一区二区三区| 日韩在线精品视频| 国产精品老女人精品视频| 麻豆av一区二区三区久久| 久久这里只有精品18| 国产女人18毛片水18精品| 欧美精品欧美精品系列c| 日韩精品资源| 日本手机在线视频| 日产国产精品精品a∨| 日韩在线第三页| 色狠狠久久av五月综合| 手机成人av在线| 日本一区二区三区在线视频| 日本一区视频在线观看免费| 日本阿v视频在线观看| 欧美一区二区高清在线观看| 欧美一区二区三区精美影视| 欧美一级片免费在线| 青青影院一区二区三区四区| 欧美综合在线第二页| 欧美成人精品欧美一级乱| 黄色一级免费大片| 国产在线观看精品| 国产麻豆一区二区三区在线观看 | 国产美女扒开尿口久久久| 国产精品亚洲片夜色在线| 国产伦视频一区二区三区 | 国产精品视频一区二区三区四| 国产成人久久精品| 国产精品久久二区| 九九久久综合网站| 一本色道久久综合亚洲二区三区| 亚洲精品中文字幕乱码三区不卡 | 日本高清不卡三区| 欧美日韩免费高清| 免费看成人午夜电影| 国产欧美日韩免费| www国产黄色| 久久久精品国产一区二区三区| 久久久久久欧美| 国产精品免费在线免费| 精品中文字幕在线| 亚洲一区二区在线看| 日本视频一区在线观看| 欧美大香线蕉线伊人久久国产精品| 精品一区二区三区毛片| 国产精品一区在线观看| 久久久免费观看| 色婷婷久久av| 精品久久一区二区三区蜜桃| 亚洲在线视频一区二区| 亚洲免费av网| 亚洲影视中文字幕| 国产精品国产对白熟妇| 国产a级片免费看| 色阁综合伊人av| 国产精品久在线观看| 亚洲一二三区精品| 欧美综合激情网| 不卡视频一区二区三区| 久久久久网址| 欧美人与性动交| 日本中文字幕一级片| 青青a在线精品免费观看| 国产日韩欧美视频在线| 久久亚洲精品欧美| 久久av在线看| 日韩经典在线视频| 国产精品专区在线| 色偷偷91综合久久噜噜| 最新av在线免费观看| 欧美连裤袜在线视频| 99热在线国产| 国产精品免费看久久久香蕉| 亚洲精品一区二区三区av| 激情小视频网站| 久久综合九色综合网站| 欧美区二区三区| 欧美影视一区二区| 91精品国产91久久久久久 | 亚洲国产精品123| 麻豆精品传媒视频| 久久99精品国产一区二区三区 | 午夜精品久久久久久久99热浪潮| 免费无遮挡无码永久视频| 国产不卡av在线免费观看| 亚洲综合欧美日韩| 精品无码久久久久久久动漫|