The length of the deck is 26.5 feet. Each post needs to be apart 6 feet from the others. To find the number of posts that will be used we need to divide the length of the deck by the distance between the posts.
Since there can't be 0.42 posts, there will be 4 posts on the deck.