A boy is climbing up a flight of $35$ steps from Level $1$ to Level $2$ of a building. If he climbs at his fastest speed for $15$ steps and slowest speed for $15$ steps, he will take $40$ seconds to climb $30$ steps. If he climbs at his fastest speed for $26$ steps and slowest speed for $9$ steps, he will reach Level $2$ from Level $1$ in $41$ seconds. Find the shortest time it will take him to reach Level $2$ from Level $1$.
The conditions for the first given hint and the second given hint are different - one is for $30$ steps total and the other one is for $35$ steps. How would I solve this?