Abstract. The notion of curvature discussed in this paper is a far going generalization of the Riemannian sectional curvature. It was first introduced by Agrachev, Barilari and Rizzi in [2], and it is defined for a wide class of optimal control problems: a unified framework including geometric structures such as Riemannian, sub-Riemannian, Finsler, and sub-Finsler structures. In this work we study the generalized sectional curvature of Carnot groups with rank-two distributions. In particular, we consider the Cartan group and Carnot groups with horizontal distribution of Goursat-type. In these Carnot groups we characterize ample and equiregular geodesics. For Carnot groups with horizontal Goursat distribution we show that their generalized sectional curvatures depend only on the Engel part of the distribution. This family of Carnot groups contains naturally the three-dimensional Heisenberg group, as well as the Engel group. Moreover, we also show that in the Engel and Cartan groups there exist initial covectors for which there is an infinite discrete set of times at which the corresponding ample geodesics are not equiregular. Acknowledgement 1. The author wishes to thank Andrei Agrachev, Davide Barilari and Luca Rizzi for their constant interest and the many helpful conversations on sub-Riemannian geometry, especially on their paper [2]. The author also would like to thank the anonymous reviewers for their constructive comments, which helped to improve the contents of the paper, especially the content of Theorem 4.2. This work was done while the author was visiting the International School for Advanced Studies (SISSA) at Trieste, Italy.