Task

In this first tutorial, we start with the introduction of different data structures, such as list, vector, and map. Write a program which can handle the following tasks:

Reserve memory for three two-dimensional points in coordinate representation. Use floating point numbers with double precision.
Assign useful values to each of the double variables according to point coordinates.
Write a function which takes the six values of the points and returns the area of the triangle.
Print the area of the triangle on the screen.

Questions

How many code lines are required to achieve this task?
How well does this source code scale for different objects?
How well does this source code scale for different dimensions?
Which improvements can be developed to ease this task?