It depends on the 55+ community. Most all of them have "Covenants, Condtions and Restrictions" (CCRs or Association "guidelines") which address length of stay for people under age 55. It can vary from community to community as each one will have their own set of guidelines.
Check with the homeowner's association or search for more information in your Association Declarations and Bylaws. Each community may be different in what they allow but most generally allow for special circumstances - particularly short-term circumstances.
It depends on your community, but most 55 and older developments allow for a certain percentage of residents who are younger. You need to check the documents that you received when you purchased your home to be sure.