Thank you for the opportunity to help you with your question!

A lies in x axis. So let it's coordinate be (x,0) and B lies on y axis and let it's coordinates be (0, y). So coordinates of midpoint be {(x+0)/2, (y+0)/2}= (x/2, y/2) given x/2=3 or x = 6 and y/2=4 or y=8. Coordinates of A is (6,0) and B is (0,8)

Please let me know if you need any clarification. I'm always happy to answer your questions.