Assignment Programming 9
Assignment Programming 9
Dr.Awad Hasballah
AL.Mahinda Mahmoud
Faculty of Computer Science & Technology.
Assignment 9
Name: Mariam Ahmed Atwa
Group: B
ID: 20220665
Question no.9:
#include <iostream>
#include <vector>
return result;
}
int main() {
vector<int> a = { 1, 4, 9, 16 };
vector<int> b = { 4, 7, 9, 9, 11 };
return 0;
}
Question no.10:
#include <iostream>
if (p1 == 0 || p2 == 0) {
return;
}
double temp = *p1;
*p1 = *p2;
*p2 = temp;
}
int main() {
double x, y;
cin >> x;
cin >> y;
sort2(&x, &y);
if (x <= y) {
cout << "true" << endl;
}
else {
cout << "false" << endl;
}
return 0;
}
Question no.11: