Sale of home after multiple periods or rental and main residence

I have owned my home for five years. Initially I rented it then used as my residence for three different periods. The total number of days l lived in the home total more than 730 days. An example is 200 days as my residence followed by renting 365 days then my residence again for 200 days followed by another rental period of 300 days then my residence again for 365 days. The total is over two years as my residence during this five year period. I lived outside the USA during the time I rented the home. Would this be considered qualified use of the home for the capital gains exclusion? I owned no other home during this period