If it is divided into steps, it should be the origin of parallelogram area algorithm.
First, pass through a vertex of the quadrilateral line and make it high to one side.
Secondly, the extended shear translation coincides with the other side to form a rectangle.
Thirdly, the area S=a*h is obtained according to the area of the rectangle.
2、y = 3x(x≤5)
2x (x≥5)
Program box: 1. Weigh the luggage. 2. Baggage weighing more than 5 kilograms shall be charged according to 2 yuan per kilogram, and luggage weighing less than 5 kilograms shall be charged according to 3 yuan per kilogram.