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

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

代做INT2067、Python編程設計代寫
代做INT2067、Python編程設計代寫

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



Assignment 1 
INT2067 Introduction to Programming and Problem Solving 
2024-2025 Semester 1 
Due Date: October 30, 2024 (Wednesday) 
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 Requirements (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 session. 
 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 f, g or c: move the fox, goose, or corn, if available, to the opposite shore 
along with the boat. [10%] 
o m: move the boat to the opposite shore without any item. [5%] 
o q: quit the game. [5%] 
 [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 lists 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 contain no spelling 
mistakes. 
7 Submission Requirements 
 Your Python file should be named as assignment1.py. Submit only the Python 
file assignment1.py through Moodle. Failure to submit the file properly will 
result in a penalty of 5 to 20 marks. 
 See Moodle for the exact time of the deadline for submission. Late submission is 
usually not accepted. You should submit earlier to avoid possibly high tra  ic 
around the deadline. 
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. 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. 
If cheating is found, both the copier and originator will get zero mark for the 
assignment. 
Repeat o  enders may result in a deduction of the course grade. 
If you have discussed the assignment with anyone, you should provide an 
acknowledgment at the end of your program file. Give the names of all classmates that 
you have discussed with. For example, your acknowledgement may look like this at the 
end of your program file: 
# Acknowledgement: I have discussed it with Thomas, Gordon, and Emily. 
10 Sample Session 1 
Welcome. 
You must 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 the items across the river. 
11 Sample Session 2 
Welcome. 
You must 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. 
References 
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





 

掃一掃在手機打開當前頁
  • 上一篇:代寫Neural Networks for Image 編程
  • 下一篇:SCC.369代做、代寫C/C++編程設計
  • 無相關信息
    合肥生活資訊

    合肥圖文信息
    急尋熱仿真分析?代做熱仿真服務+熱設計優化
    急尋熱仿真分析?代做熱仿真服務+熱設計優化
    出評 開團工具
    出評 開團工具
    挖掘機濾芯提升發動機性能
    挖掘機濾芯提升發動機性能
    海信羅馬假日洗衣機亮相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;">

                蓝色福利精品导航| 精品伊人久久久久7777人| 色噜噜狠狠一区二区三区果冻| 午夜电影一区二区三区| 久久亚区不卡日本| 欧美日韩高清影院| 日本高清免费不卡视频| 久久精品国产精品亚洲精品| 亚洲欧美日韩国产综合在线| 久久精品视频一区| 日本欧美在线看| 国产suv精品一区二区三区| 国产高清在线精品| 成人听书哪个软件好| 午夜在线成人av| 国产在线播放一区三区四| a在线欧美一区| 欧美老肥妇做.爰bbww视频| 久久久午夜电影| 一区二区三区波多野结衣在线观看| 蜜桃视频一区二区| 色美美综合视频| 久久久亚洲国产美女国产盗摄| 亚洲一二三四在线观看| 成人sese在线| 久久丝袜美腿综合| 精品无码三级在线观看视频| 欧美一区三区二区| 午夜精品视频一区| 欧美日韩高清一区二区三区| 亚洲色大成网站www久久九九| 久久成人综合网| 欧美性受xxxx黑人xyx| 亚洲男女毛片无遮挡| 97久久精品人人爽人人爽蜜臀| 日本一区二区视频在线| 成人激情动漫在线观看| 亚洲美女视频在线观看| voyeur盗摄精品| 亚洲图片另类小说| 日韩欧美国产电影| 久久99精品视频| 国产网站一区二区| 99精品在线观看视频| 亚洲猫色日本管| 欧美精品v日韩精品v韩国精品v| 国产校园另类小说区| 国产专区欧美精品| 久久综合九色综合久久久精品综合 | 日本精品视频一区二区| 欧美国产日韩a欧美在线观看| 国产一区二区美女诱惑| 久久九九国产精品| 福利视频网站一区二区三区| 精品久久久久久无| 国产在线不卡一卡二卡三卡四卡| 91精品一区二区三区在线观看| 中文字幕中文字幕一区| 97久久人人超碰| 亚洲电影一区二区三区| 欧美亚洲综合色| 日韩影院免费视频| 精品少妇一区二区三区在线播放| 麻豆国产一区二区| 国产欧美一区二区精品性色| 国产91清纯白嫩初高中在线观看 | 99国产一区二区三精品乱码| 亚洲视频狠狠干| 欧美性视频一区二区三区| 免费在线看成人av| 欧美激情资源网| 91成人看片片| 精品一区二区三区蜜桃| 亚洲精品videosex极品| 欧美一级艳片视频免费观看| 成人精品在线视频观看| 午夜精品免费在线| 精品国产网站在线观看| 成人av手机在线观看| 午夜精品福利一区二区三区av | 中文乱码免费一区二区| 久久中文字幕电影| 欧美哺乳videos| 精品粉嫩超白一线天av| 中文字幕av一区 二区| 波多野结衣中文字幕一区二区三区| 一区二区三区欧美视频| 欧美激情在线观看视频免费| 91精品久久久久久蜜臀| 国产一区二区三区在线观看精品| 一区二区三区在线不卡| 依依成人精品视频| 亚洲黄色免费电影| 亚洲黄一区二区三区| 亚洲日本丝袜连裤袜办公室| 一区二区三区在线免费观看 | 色94色欧美sute亚洲线路一ni | 日韩一区和二区| 美国毛片一区二区| 国产高清在线观看免费不卡| 91在线观看视频| 欧美日韩视频在线第一区| 欧美日韩亚洲高清一区二区| 久久久一区二区三区| 亚洲一区免费在线观看| 国产美女一区二区| 欧美精品在线观看播放| 中文字幕在线不卡一区二区三区| 亚洲国产精品久久人人爱蜜臀 | 捆绑紧缚一区二区三区视频| 欧洲精品一区二区三区在线观看| 91免费观看视频| 国产精品一区二区不卡| 依依成人精品视频| 一区在线观看视频| 欧美变态口味重另类| 在线免费一区三区| 欧美四级电影在线观看| 国产精品理论片在线观看| 欧美日韩精品欧美日韩精品| 成人av免费在线观看| 色诱视频网站一区| 这里只有精品视频在线观看| 日韩女优制服丝袜电影| 欧美国产一区在线| 最新中文字幕一区二区三区| 亚洲男人的天堂在线观看| 亚洲午夜在线电影| 日本欧美韩国一区三区| 国产乱码精品一区二区三区忘忧草| 国产成人一级电影| 91电影在线观看| 日韩欧美二区三区| 中文字幕在线观看不卡视频| 午夜精品一区二区三区免费视频 | 性做久久久久久免费观看欧美| 日韩高清国产一区在线| 成人一级视频在线观看| 欧美亚洲综合在线| 精品国产污污免费网站入口| 亚洲品质自拍视频| 久久99久国产精品黄毛片色诱| 波多野结衣中文字幕一区二区三区| 制服丝袜在线91| 亚洲日本乱码在线观看| 黑人巨大精品欧美黑白配亚洲 | 紧缚捆绑精品一区二区| 色哟哟日韩精品| 欧美一级日韩免费不卡| 亚洲男人的天堂在线观看| 国内精品视频666| 欧美性大战久久久久久久蜜臀| 久久久激情视频| 日韩在线观看一区二区| 91网站最新网址| 看国产成人h片视频| 亚洲激情自拍视频| 国产精品一二三区在线| 日韩一级欧美一级| 亚洲一区二区三区中文字幕在线| 国产精品性做久久久久久| 7777精品伊人久久久大香线蕉的 | 久久成人免费电影| 在线视频欧美区| 国产精品毛片大码女人| 久久精品av麻豆的观看方式| 欧美中文字幕亚洲一区二区va在线 | 亚洲国产成人午夜在线一区| 日韩电影免费在线看| 在线欧美一区二区| 亚洲色欲色欲www在线观看| 国产成人精品www牛牛影视| 日韩精品一区二区在线| 五月综合激情网| 在线精品视频一区二区三四| 国产精品不卡在线观看| 成人自拍视频在线观看| 精品国产伦一区二区三区观看方式 | 久久久av毛片精品| 五月婷婷激情综合网| 欧洲一区二区av| 亚洲色图视频网| 99在线精品一区二区三区| 亚洲国产成人自拍| www.久久久久久久久| 中文字幕日韩一区| 一本大道久久a久久精二百| 中文字幕亚洲成人| 91在线porny国产在线看| 中文字幕亚洲欧美在线不卡| 成人福利视频在线看| 国产拍欧美日韩视频二区| 国产精品系列在线播放| 国产亚洲婷婷免费| 成人午夜看片网址| 亚洲视频在线一区| 欧美亚洲动漫另类| 亚洲成人自拍网| 欧美区一区二区三区| 日本美女一区二区三区|