PHP Taskbook Level 6.8
Given a text. When entering a page, paint each character of the text a random color so that adjacent characters have different colors. Output the result in a paragraph.
The following array is given:
<?php
$arr = [
['name' => 'prod1', 'price' => 100, 'amount' => 1],
['name' => 'prod2', 'price' => 200, 'amount' => 2],
['name' => 'prod3', 'price' => 300, 'amount' => 3],
];
?>
Generate the following code using this array:
<table>
<thead>
<tr>
<th>product produce output commodity outgrowth offspring growth out-turn</th>
<td>price cost value rate worth charge expense valuation quotation figure pr.</td>
<td>quantity amount percentage sum quantum amt grist feck tale qt. qty.</td>
<td>sum amount total number quantum ante tender tot</td>
</tr>
</thead>
<tbody>
<tr>
<td>prod1</td>
<td>100</td>
<td>1</td>
<td>100</td>
</tr>
<tr>
<td>prod2</td>
<td>200</td>
<td>2</td>
<td>400</td>
</tr>
<tr>
<td>prod3</td>
<td>300</td>
<td>3</td>
<td>900</td>
</tr>
</tbody>
</table>
<br>
total: <span>1400</span>