here is part b for pursu chapter 7 for MD array
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Chapter 7 pursu</title>
</head>
<body>
<h2> Console Wars</h2>
<?php
/* pursu chapter 7 B
* creating a multidimensional array
*/
//creating a MD array:
$company = array(
1 => 'Microsoft','Nintendo', 'Sony');
$console = array(
1 => 'Xbox 360','Wii U','Playstation 3');
$firstparty = array(
1 => 'Halo', 'Mario', 'God Of War');
$best = array(
'Maker' => $company,
'System' => $console,
'mascot' => $firstparty );
print "<p>The last-gen console race begin with {$best['Maker'][1]} Xbox 360";
print "<p>The first next-gen console will be Nintento's {$best['System'][2]}";
print "<p>The most brutal first party title is Sony's {$best['mascot'][3]}";
foreach ($best as $name => $consolz){
foreach ($consolz as $game => $consoles){
print "<p>The gaming system by company, console and flagship title: $consoles\n</p>";
}
}
?>
</body>
</html>
And for C the issue I have been having with PHP is that I can read the code but up until now I struggle with
constructing my own code. Can you explain that part to me and how to construct that problem?