This paper deals with the issue of charging and discharging electric vehicles in public parking lots based on maximizing the parking's benefit. In this regard, a controlled charging/discharging scheduling algorithm is proposed. The optimization procedure guarantees the sale (purchase) of energy from (for) electric vehicles at high (low)-price periods. The effectiveness of the proposed strategy is compared with two uncontrolled strategies including constant time and constant power-based scheduling. The analysis approach is formed by considering the uncertainty of arrival and departure times and state of charge of electric vehicles. As the historical data of the literature does not include all possible scenarios in the process of arrival to departure, the required data have been generated using statistical methods. Accordingly, several scenarios are considered in the formation of a comprehensive database. The scheduling tables obtained from the strategies are evaluated through financial analysis in which the parking's energy consumption cost and its benefit derived from the charging/discharging services and rent of parking space are calculated. In a comparative analysis, the capability of a two-level benefit-based scheduling algorithm are investigated to reduce energy consumption cost and increase parking's benefit. Numerical results confirm the effectiveness of the proposed strategy.