Its like asking how long a car can last.
Apple makes it difficult to continue using them
Apple just has the decency to communicate what hardware it considers to be officially obsolete.
Let me reiterate, what computer manufacturer provides Apple’s level of support for more than 7 years?