Number of integer triangles. 
Number of integer isosceles or equilateral triangle none of whose
  sides exceed $2c$ is?

I substituted $c =3$ checked, and got $27= 3 \times (3^2)$ i.e. $3c^2$ triplets. It gives the right answer($3c^2$) but how do I write a proper formal proof of this?
I tried it this way: We have three vacant places for three integers. First place can be filled in $2c$ ways, 2nd one in $2c$ ways, 3rd one in $2c$ way but it involves over-counting, is it possible to eliminate the extras? 

Let $b$ be the length of the base and $a$ be the length of the legs of such a triangle. Given $c\geq1$ we want
$$1\leq b\leq 2c, \quad {b\over2}<a\leq 2c\ .\tag{1}$$
If $b=2k-1$ with $1\leq k\leq c$ is odd the condition $(1)$ enforces $k\leq a\leq 2c$ and allows of $2c-(k-1)$ different integer values for $a$.
If $b=2k$ with $1\leq k\leq c$ is even then $(1)$ enforces $k+1\leq a\leq 2c$ and allows of $2c-k$ different integer values for $a$.
The total number $N$ of isosceles triangles having sides $\leq2c$ therefore is given by
$$N=\sum_{k=1}^c\bigl(2c-(k-1)\bigr)+\sum_{k=1}^c(2c-k)=4c^2-\sum_{k=1}^c(2k-1)=3c^2\ .$$
