#include "iostream"\n#include "vector"\n\nusing namespace std;\n\nint main() {\n int n;\n cout << "Enter the dimension of the vectors: " ;\n cin >> n;\n\n vector veca(n), vecb(n);\n\n cout << "Enter the elements of vector a: " ;\n for (int i = 0; i < n; i++) {\n cin >> veca[i];\n }\n\n cout << "Enter the elements of vector b: " ;\n for (int i = 0; i < n; i++) {\n cin >> vecb[i];\n }\n\n int dotProduct = 0;\n for (int i = 0; i < n; i++) {\n dotProduct += veca[i] * vecb[i];\n }\n\n cout << "Dot product of the vectors: " << dotProduct << endl;\n\n return 0;\n}