how to call square methode in main methode