I looked up Apple's official warranty; it states that it "is a voluntary manufacturer’s warranty. It provides rights separate to rights provided by consumer law", so I guess you get the 'good' warranty for a year, then whatever else is required by law?
Either way, I tend to keep my Apple computers running for about five years before an upgrade tempts me, my current iPhone is a 6s from 2015 and it's still going strong (heavy caveat: I have replaced the battery), and I've a first-generation iPod that still works fine for the 45 minutes its battery holds charge for.
I've had two Apple computers fail on me in less than five years — a MacBook Pro that ended up being involved in the Nvidia recall of about a decade ago, and a 2015 Retina MacBook that failed without any connection to a recall programme. In the latter case there was some sort of thermal issue, but they fixed it for free despite being quite far out of warranty.
Those two contrast with another ten or eleven Macs that I've either owned, or been given possession of through work, due primarily to my bad habit of almost always changing jobs after two years but also because a couple of my employers have allocated multiple Macs to me. They're pretty much pervasive throughout US tech.
Additionally, I had every iPhone through to the 6s and never a failure, though I separately had a fourth-generation iPad at some point that failed. My first-generation iPad is still going strong, though for that matter so is my Nexus 5x and my Nexus 7 2013, both of which have famous issues, so probably my anecdotes in net aren't that valuable.