Over time, sentiment analysis and opinion mining emerged as significant study areas. In order to determine a person's mood from a written text, sentiment analysis examines texts, feelings, and views and divides them into positive and negative categories. Sentiment analysis is used on social media sites, where enormous amounts of data are created daily. Fewer studies have been conducted on the Arabic language compared to those conducted on the English language because of how difficult and complicated sentiment analysis is in the morphologically complex Arabic language. The Coronavirus pandemic was one of the factors that increased the amount of research being published in the area of sentiment analysis, which was then utilized to identify and categorize people's emotions throughout the Coronavirus era. In order to categorize a group of brief texts about employees' opinions on working from home during the coronavirus pandemic into binary positive and negative feelings and to identify the challenging aspects, or the issues that employees face while working from home, so that business owners can review and address them, machine learning algorithms were used in this study. Additionally, other lengthy writings on the same subject were subjected to the same algorithms so that we could monitor the model's progress while we worked on both short and long texts. With the aim of determining if text length may affect efficiency and accuracy, it was discovered that working with lengthy texts increased accuracy. The machine learning techniques Logistic Regression (LR), Random Forest (RF), Multinomial Naive Bayes (MNB), and Support Vector Classification (SVC) have been chosen and used. According to the results, MNB performs best when dealing with short texts, outperforming the competition with an accuracy rate of 88.5 %. It is followed by LR, RF, and SVC, which each achieve accuracy rates of 87.6 %, 78.1 %, and 87.6 %. SVC wins the competition when applied to lengthy texts, with an accuracy rate of 98.5 %, followed by LR, MNB, and RF, with accuracy rates of 97.6 %, 96.6 %, and 97.5 %, respectively.