diff --git a/Question08-Function/Ex04.php b/Question08-Function/Ex04.php index 40099aa..5342da8 100644 --- a/Question08-Function/Ex04.php +++ b/Question08-Function/Ex04.php @@ -7,7 +7,16 @@ * * 引数で渡された値の前後に 「 」 を付与して出力する関数("「"と引数と"」"の連結) */ +function convertMessage($str) +{ +$result = "「". $str. "」" ; + + return $result; +} $message = 'Hello, world!'; // TODO: 関数convertMessageを(変数messageを引数に)で呼び出してください +$result = convertMessage ($message); + +echo $result ; \ No newline at end of file