Computers typically last 3 to 8 years, depending on the brand, quality, and how well you take care of it. Desktops tend to last slightly longer than laptops.
Standard manufacturer warranties typically last 6 months to 3 years and cover the original owner. Check your computer's warranty policy if it is fairly new and has problems with its hardware that were not caused by you. This might include:
Broken keyboard or keys
Monitor defects
Malfunctioning modem
Problems with internal component