Sequence and Series Question

Hey everyone. I haven't been on in quite some time, but I guess that was due to not having school, although I do think I should've helped out those who had similar problems as I did, but I am sorry. Anyways, I just started Precalculus, and I had a question that I was quite confused on. Well anyway, here goes....

How many terms are in the sequence 4,7,10.....40?

Now i know I could do this the long way by doing it manually, but I forget the formula or way to do it to get it in a much simpler way. I would appreciate anyone that can help me with this and bid you all a good day.:)

Edit: I also forgot that I put this in the wrong section with elementary/middle school math questions, when it belongs in the high school math section, namely in Pre-Calculus, so I am sorry about that.