As an English learner, I have been confused about the position of the adverb from the beginning. Here is a question which puzzles me:
A) It only took him ten minutes to do the test.
B) It took him only ten minutes to do the test.
Are they both grammatically correct? It will be appreciated if anyone could give me a detailed explanation.