You should use the TVM facility on your calculator
Question 1 - Enter I=15, PV=-17000, PMT=0,FV=32300,P/Y=1,C/Y=1. Then solve this for N. The answer = 4.59 years.
You should see that PV is negative and FV is positive. Think of a positive number as an amount you receive - it's always great to get money. Then PV is negative because you have to pay it into an account sopmewhere, so this money leaves you. Think of paying out money as being negative.
I=15 shows the annual interest rate.
PMT = 0 because you are not making any payments each year - if you did make regular payments, enter this amount as a negative because you are paying money which leaves you.
C/Y indicates the number of compounding periods per year (ie how many times interest is calculated and added to the account). In this case, interest is paid once a year.
P/Y is the number of regular Payments made each year. You can make this the same number as C/Y but will be disregarded in the calculator's working since PMT=0 has been set.
Question 2 - Enter I=10, PV=-20000, PMT=0, FV=32000,P/Y=1,C/Y=1. Then solve this for N. The answer = 3.36 years.
If this question is related to Question 1, you should check that the two values you gave for the amount invested are not the same.