下列程序的运行结果是6641,请将横线处缺失程序补充完整() #inclu...
发布于 2022-03-03 15:12:20
下列程序的运行结果是6641,请将横线处缺失程序补充完整()
#include#include#includeusing namespace stdint main(){int iarray[]={1,1,2,7,4,6,5}vectorivector(iarray,iarray+sizeof(iarray)/sizeof(int)) int iarray1[]={2,7} vectorivector1(iarray1,iarray1+sizeof(iarray1)/sizeof(int)) int iarray2[]={4,6} vectorivector2(iarray2,iarray2+sizeof(iarray2)/sizeof(int)) cout<<(find_end(ivector.begin(),ivector.end(),ivector1.begin(),ivector1.end())+3) cout<<(find_first_of(ivector.begin(),ivector.end(),ivector1.begin(),ivector1.end())+3) cout<<search(ivector.begin(),ivector.end(),ivector2.begin(),ivector2.end()) cout<<search_n(ivector.begin(),ivector.end(), equal_to())<<endl return 0 }int iarray1[]={2,7}vectorivector1(iarray1,iarray1+sizeof(iarray1)/sizeof(int)) int iarray2[]={4,6} vectorivector2(iarray2,iarray2+sizeof(iarray2)/sizeof(int)) cout<<(find_end(ivector.begin(),ivector.end(),ivector1.begin(),ivector1.end())+3) cout<<(find_first_of(ivector.begin(),ivector.end(),ivector1.begin(),ivector1.end())+3) cout<<search(ivector.begin(),ivector.end(),ivector2.begin(),ivector2.end()) cout<<search_n(ivector.begin(),ivector.end(), equal_to())<<endl return 0 }int iarray2[]={4,6}vectorivector2(iarray2,iarray2+sizeof(iarray2)/sizeof(int)) cout<<(find_end(ivector.begin(),ivector.end(),ivector1.begin(),ivector1.end())+3) cout<<(find_first_of(ivector.begin(),ivector.end(),ivector1.begin(),ivector1.end())+3) cout<<search(ivector.begin(),ivector.end(),ivector2.begin(),ivector2.end()) cout<<search_n(ivector.begin(),ivector.end(), equal_to())<<endl return 0 }cout<<(find_end(ivector.begin(),ivector.end(),ivector1.begin(),ivector1.end())+3) cout<<cout<<(find_first_of(ivector.begin(),ivector.end(),ivector1.begin(),ivector1.end())+3)cout<<search(ivector.begin(),ivector.end(),ivector2.begin(),ivector2.end()) cout<<cout<<search_n(ivector.begin(),ivector.end(), equal_to())<<endl return 0 }return 0}
登录后免费查看答案
关注者
0
被浏览
34