Write the scalar product operator (*) for the Vector class. The following code must work:
Vector2(2, 6) * Vector2(5, -1) // 4.0Write the scalar product operator (*) for the Vector class. The following code must work:
Vector2(2, 6) * Vector2(5, -1) // 4.0Sample Input 1:
Vector2(2, 6)
Vector2(5, -1)Sample Output 1:
4.0Create a free account to access the full topic