variables - Why compilation fails? [Java] -


interface rideable {      string getgait();  }  public class camel implements rideable {      string getgait() { return " mph, lope"; }  } 

why compilation fail? don't know why compile error?

by default modifier interface's method public. when implement it. need public. add public getgait method should resolve it


Comments

Popular posts from this blog

compilation - PHP install fails on Ubuntu 14 (make: *** [sapi/cli/php] Error 1) PHP 5.6.20 -

php - Passing multiple values in a url using checkbox -

java - nested exception is org.hibernate.exception.SQLGrammarException: could not extract ResultSet Hibernate+SpringMVC -