Abstract: Heart disease is a common problem that can be very serious in the elderly and also in individuals who do not have a healthy lifestyle. In addition to maintaining a decent eating habit, it can prevent it to some extent with periodic check-up and diagnosis. Hos pitals produce a large amount of patient data, such as x-ray results, lung results, heart pain results, chest pain results; personal health records (PHRs), etc. Based on the symptoms, which are explicitly the attributes needed for prediction, the decision tree classifier is implemented. Using the decision tree algorithm, we will be able to classify certain attribute s which are the best ones that will lead us to a better prediction of the datasets. The data that is generated from the hos pitals are not used effectively. S ome of these tools are used to extract data from the heart disease detection database, and other functions are not accepted. Various optimization algorithms such as (Fuzzy Logic, Random Forests, and Q-Learning), deep learning algorithms and health care data are used in this report to identify patients whether or not they have heart diseases according to the details in the record. Try to use the data as a model that tells the patient whether or not they have heart disease.Keywords: Fuzzy Logic, Random Forests, and Q-Learning, machine learning.