operator * method

Point operator *(
  1. double scalar
)

Multiply this point by scalar (scalar multiplication).

Implementation

Point operator *(double scalar) => Point(x * scalar, y * scalar);