Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

第三次作业 #3

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

chuckbruno
Copy link

1、第一个函数缺少模版参数template,故加上;
2、逐元素相加首先找出a、b元素的共同类型,然后再找到a、b size小的那个值,然后再逐元素相加就行;
3、variant + variant用visit配合lambda就能实现;
4、variant + vector,因为这里不知道vector的具体类型,所以我重载了两个方法(感觉不够灵活);
5、最后打印variant、也是visit配合lambda使用;

我再研究下老师说得那个加分项怎么实现。

@chuckbruno chuckbruno changed the title update template codes 第三次作业 Dec 26, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant