We have been renting our retirement home out for several years. The renters have moved out and we are moving in. Can we deduct the cost of repainting and putting in new flooring?
That depends on which country you are in.
In Australia it depend if it is for general wear and tear or if it needs replacing/repairing due to damage by the tenant. If it is due to general wear and tear, then no you cannot deduct it. If it is for damage and you can't use the money from the bond or insurance, then yes it will be deductible.
This answer may differ considerably in different countries due to different tax laws and rules.