Max builds rail fences. For one one style of fence, each section use 3 vertical fence post and 6 horizontal rails. How many rails does he need for a fence that has 18 post?