How to add number of fields throughout file together?

So, I have three problems that cover this subject.

First one asks me to find the number of fields in the file that contain the substring "he". I found the number of fields, but the problem I have is that they are displaying by each record. I want to add all of the records' fields together.
With this same text document:

"The quick brown fox jumped over the lazy dog's back.
The rain in Spain falls mainly on the plain.
The rain in Spain also falls on the mountains."
My code looks like this:

{print "Number of fields in record containing 'he': " index($0, "he")}

It is giving me this result:

"Number of fields in record containing 'he': 2
Number of fields in record containing 'he': 2
Number of fields in record containing 'he': 2"
What I want it to do is print

"Number of fields in file containing 'he': 6"
How would I accomplish that?

These are the two other problems, of a very similar type: I want to find the number of times the letter n appears in the text file, but I do not know how to add all the records' results together. My current code looks like this:

{print "Number of 'n' in record: " gsub(/n/, "")}

This gives me the result of:

"Number of 'n' in record: 1
Number of 'n' in record: 6
Number of 'n' in record: 6"
Instead, I need it to say

"Number of 'n' in file: 13"
The last problem is essentially the same, but instead of 'n', I need to look for the number of 'la' in the file.

Welcome,
This looks like home work to me, so unless you can justify, the thread is closed, as we have a forum dedicated to home/classwork with its own rules you have to comply with

Do not post classroom or homework problems in the main forums. Homework and coursework questions can only be posted in this forum under special homework rules.

Please review the rules, which you agreed to when you registered, if you have not already done so.

More-than-likely, posting homework in the main forums has resulting in a forum infraction. If you did not post homework, please explain the company you work for and the nature of the problem you are working on.

If you did post homework in the main forums, please review the guidelines for posting homework and repost.

Thank You.

The UNIX and Linux Forums.