Skip to content

Instantly share code, notes, and snippets.

@fermopili
Created March 19, 2017 12:21
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save fermopili/fc7333525d1fd322d7310f842cb30b76 to your computer and use it in GitHub Desktop.
Save fermopili/fc7333525d1fd322d7310f842cb30b76 to your computer and use it in GitHub Desktop.
com.javarush.task.task13.task1310
/*
CleverMan и SmartGirl
*/
public class Solution {
public static void main(String[] args) throws Exception {
}
interface Person {
void use(Person person);
void startToWork();
}
interface Workable {
boolean wantsToGetExtraWork();
}
interface Secretary extends Person{
}
interface Boss extends Person, Workable{
}
class CleverMan implements Boss{
public void use(Person person) {
person.startToWork();
}
public void startToWork() {
}
public boolean wantsToGetExtraWork() {
return true;
}
}
class SmartGirl implements Secretary{
public void use(Person person) {
}
public void startToWork() {
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment