Last active
May 23, 2018 04:35
-
-
Save nahidulhasan/3369ec984dba4ff6c6bf4293612f26fa to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
interface WorkAbleInterface | |
{ | |
public function work(); | |
} | |
interface SleepAbleInterface | |
{ | |
public function sleep(); | |
} | |
class HumanWorker implements WorkAbleInterface, SleepAbleInterface | |
{ | |
public function work() | |
{ | |
var_dump('works'); | |
} | |
public function sleep() | |
{ | |
var_dump('sleep'); | |
} | |
} | |
class RobotWorker implements WorkAbleInterface | |
{ | |
public function work() | |
{ | |
var_dump('works'); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment