VC驿站

 找回密码
 加入驿站

QQ登录

只需一步,快速开始

搜索
查看: 850|回复: 0

[讨论] 海外大学C++入门课练习题: Queue, Class, Stack

[复制链接]
49_avatar_middle
最佳答案
0 
在线会员 发表于 2020-10-8 02:18:42 | 显示全部楼层 |阅读模式
Assume you are in main.cpp define a function that is NOT SCOPED to any class. It is NOT a member of the ListInterface nor LinkedList classes. Your function should accept two lists. You will remove all values from the first list that are present in the second list. Example:
Lists before call:                                         Lists after call:
target: A, B, C, A, D, C, E, F, B, C, A                        target: A, A, D, E, F, A
toRemove: C, B, Q, Z                                        toRemove: C, B, Q, Z


template <typename T>
void removeHelper(ListInterface<T>& target, const ListInterface<T>& toRemove) {
//your code below




上一篇:new创建内存
下一篇:[C++]自己写了个简单的xml解析,求大佬指点(多图警告)
您需要登录后才可以回帖 登录 | 加入驿站 qq_login

本版积分规则

×【发帖 友情提示】
1、请回复有意义的内容,请勿恶意灌水;
2、纯数字、字母、表情等无意义的内容系统将自动删除;
3、若正常回复后帖子被自动删除,为系统误删的情况,请重新回复其他正常内容或等待管理员审核通过后会自动发布;
4、感谢您对VC驿站一如既往的支持,谢谢合作!

关闭

站长提醒上一条 /2 下一条

QQ|小黑屋|手机版|VC驿站 ( 辽ICP备09019393号-4 )|网站地图wx_jqr

GMT+8, 2023-5-29 23:00

Powered by CcTry.CoM

© 2009-2021 cctry.com

快速回复 返回顶部 返回列表