I have learned the use of Direct object and indirect object. But I've got confused with this use. Please check my knowledge.
He gives me a book.
He gives a book to me.
The second sentence is said to be wrong( according to a book).
It is said "to" should not be used before "pronouns", but should be used before "nouns".
I am a learner, and I believe you don't know how to find a direct or indirect object in a sentence.
Ask yourself the following question: ' What he gives? the answer is 'a book'. The noun book is the direct object and it's the same thing for the second phrase.
For indirect object you have generally a preposition between the verb and the subject.
Hope it's help you.
Have a nice day and do not forget to change your grammar book.