Prognostic Impact of Non-Cardiac Comorbidities on Long-Term Prognosis in Patients with Reduced and Preserved Ejection Fraction following Acute Myocardial Infarction