<?php $array = ['Dog:110', 'Cat:111', 'Mouse:101']; $result = []; foreach ($array as $v) { [$k, $result[$k]] = sscanf($v, '%[^:]:%d'); } var_export($result);
You have javascript disabled. You will not be able to edit any code.
Value for `_results` contains invalid data `array`