BBUM - Editorial

PROBLEM LINK:

Practice
Contest

Author: Najiba Halim
Tester: Amitkumar Jha
Editorialist: Najiba Halim

DIFFICULTY:

Cakewalk

PROBLEM:

Find total number of hexagons after combining hexagons around the constructed lattice n times.

QUICK EXPLANATION:

Answer is n^{3}

EXPLANATION:

The number of hives Bumble has used each day are centered hexagonal numbers.

An n^{th} centered hexagonal number is given by the formula, n^{3} - (n-1)

Hence, \sum_{x=1}^{n} (x^{3} - (x-1)^{3}) = n^{3}