The commission of selling each iPhone is $30 and the commission of selling each iPad is $20. If you one day sold 4 more iPhones than iPads and earned a total commission of $520, how many iPhones and iPads did you sell respectively?