Major depressive disorder (MDD) is a common mental disorder affecting the lives of about 280 million people and increasing rates of suicidal mortality. The current methods of diagnosis of depression are subjective, time-consuming, expensive, and inaccurate because of its heterogeneous symptoms that overlap with other disorders. In this paper, we exploit the potential of the fusion of artificial intelligence (AI) and electroencephalogram (EEG) to revolutionize the automatic diagnosis of depression and compare the classification performance of machine learning (ML) and deep learning (DL) based techniques. Results from the analysis of data recorded from 46 subjects (23 MDD and 23 Control) show that the ML methods, particularly the ensemble model with the Dempster-Shafer combination rule outperforms other models, achieving an accuracy of 99.62% and showing robustness to the variations in the data. Our work also includes a study on the effect of various hyper-parameters, in particular the number of EEG channels, feature selection methods, number of selected features, and segmentation length on the model performance. The AI-EEG integration can enhance the accuracy of diagnosis, enable personalized treatment plans, and improve patient outcomes. Continued research, development, and validation of AI algorithms, in conjunction with ethical considerations, will be crucial to harness the full potential of this technology in mental healthcare.