COVID-19 is a pandemic that has caused lot of deaths and infections in the last 6 months and is showing an increasing trend not only in the number of infections and deaths, but also in the recovery rate. Accurate prediction models are very much essential to make proper forecasts and take necessary actions. This study demonstrates the capability of Multilayer Perceptron (MLP, an ANN model for forecasting the number of infected cases in the state of Karnataka in India. It is trained using a fast training algorithm namely, Extreme Learning machine (ELM) to reduce the training time required. The parameters required for the forecasting model have been selected using partial autocorrelation function (PACF), which is a conventional method and its performance has been compared with parameters selected using cuckoo search (CS) algorithm, which is a very popular nature-inspired optimization algorithm. The testing of the forecasting model has been done and comparison between the two parameter selection methods has been carried out. Use of CS algorithm has resulted in a better forecasting performance based on mean absolute percentage error (MAPE), with a value of 6.62 % on training data and 7.03% on the test data. Further to check the efficacy of the model, the data of COVID-19 cases of Hungary from 4th March to 19th April 2020 has been used, which resulted in a MAPE of 1.55%, thereby establishing the robustness of the proposed ANN model for forecasting COVID-19 cases for the state of Karnataka.