"I have a banana and pear" sounds wrong to me. However, you will find certain English phrases where the second article is omitted because the two objects are to be seen as parts of a pair: "there was a hammer and sickle on the flag of the USSR" or "I have a mortar and pestle." Your banana and pear, though, are not related to each other in the way that a mortar is related to a pestle.