On the first day of the sale of tickets of a drama. 35 tickets in all were sold. If the rates of the tickets were Rs.20 and Rs.40 per ticket and the total collection was Rs. 900. Find the number of tickets sold of each rate.