Skip to content

Instantly share code, notes, and snippets.

@nahidulhasan
Last active May 23, 2018 04:35
Show Gist options
  • Save nahidulhasan/3369ec984dba4ff6c6bf4293612f26fa to your computer and use it in GitHub Desktop.
Save nahidulhasan/3369ec984dba4ff6c6bf4293612f26fa to your computer and use it in GitHub Desktop.
<?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