24小时热门版块排行榜    

CyRhmU.jpeg
查看: 553  |  回复: 0

mit95

金虫 (小有名气)

[求助] 计算机科学导论作业,求帮助!需要答案代码!

Exercise 1 Develop a data definition ManyNumbers which can store arbitrarily many numbers.

Exercise 2 Develop a data and structure definition for storing pairs of numbers representing x and y coordinates.

Exercise 3 Develop a data definition ManyPairs which can store arbitrarily many pairs of numbers using the data definition from the previous exercise.

Exercise 4 Write the templates for all of the three data definitions you have defined.

Exercise 5 Design a function, which, given ManyPairs, draws all of the points as circles with radius 10 on the same empty scene, producing the resulting image.

Exercise 6 Design a function, which, given ManyPairs and two numbers for x and y coordinates, creates a larger ManyPairs with all of the coordinates plus the new pair of coordinates.

Exercise 7 Using the functions you developed in exercise 5 and 6, design a big-bang program which places a circle on every mouse event at the location of the mouse event. Note that this is similar to, but not exactly the same as, the Challenge Exercise from

» 猜你喜欢

http://q.gs/38aUd
已阅   回复此楼   关注TA 给TA发消息 送TA红花 TA的回帖
相关版块跳转 我要订阅楼主 mit95 的主题更新
信息提示
请填处理意见