PHP - Interfaces and Traits
Consider this code:
What will be the output?
interface Config {
const DEFAULT = 'none';
}
class Settings implements Config {
public function getDefault() {
return self::DEFAULT;
}
}
class CustomSettings extends Settings {
const DEFAULT = 'custom';
}
$custom = new CustomSettings();
echo $custom->getDefault();What will be the output?
