i'm getting this error when i am trying to run my first script.Can anyone please help me
The code you have written might have worked if you would have used Firefox version lesser than 48 and webdriver 3. At that time firefox driver was implemented as a xpi based plugin; that was the reason why it was different from IE and Chrome where you explicitly needed to set the system property.
In short if you want to fix the issue, please add the below code to your class.
System.setProperty("webdriver.gecko.driver", "path to your gecko driver");