O’g’li (sirtqi) guruh
Download 42.58 Kb.
|
O’g’li (sirtqi) guruh
- Bu sahifa navigatsiya:
- Dastur natijasi
Dastur kodi:
#include #include #include using namespace std; int main() { list list list list list list list3 = list1; list4 = list2; cout<<"Berilgan to`plam : \n"; for (it = list1.begin(); it != list1.end(); it++) {
for (iter = list2.begin(); iter != list2.end(); iter++) { cout << *iter << " "; }; cout<<"\n"; for (it = list1.begin(); it != list1.end(); it++) { int k = *it; if(k % 2 == 0) { int c = 0; for (iter = list2.begin(); iter != list2.end(); iter++) { int a = *iter; if(a == k) c++; } if(c>=1) cout<<"\nBerilgan to`plamdagi "< }; for (it = list3.begin(); it != list3.end(); it++) { int k = *it; list2.remove(k); } for (it = list4.begin(); it != list4.end(); it++) { int k = *it; list1.remove(k); } cout<<"\nSaralangan 1-to`plam : \n"; for (it = list1.begin(); it != list1.end(); it++) {
for (iter = list2.begin(); iter != list2.end(); iter++) { cout << *iter << " "; }; return 0; } Dastur natijasi: 1 Дастур Visual C++ муҳитида тузилган. Download 42.58 Kb. Do'stlaringiz bilan baham: |
Ma'lumotlar bazasi mualliflik huquqi bilan himoyalangan ©fayllar.org 2024
ma'muriyatiga murojaat qiling
ma'muriyatiga murojaat qiling