1. Form an array T from a one-dimensional array X of n elements according to the rule:
$T_1=X_1, T_2=X_1+X_2, ..., T_n=X_1+X_2+...X_n$
2. Find the total gravity of the N-layer spherical shell with the inner diameter D,
if the outer diameters of the layers are equal: D + 1, D + 2, ..., D + N,
and the specific gravity of the material of the layers is respectively: G, G / 2, ..., G / N.
The layers fit tightly together.