I hereby claim:
- I am mcneely on github.
- I am mcneely (https://keybase.io/mcneely) on keybase.
- I have a public key ASALsPXAAv2LOIE1ApE8dxwltfLBFA2AN0T7L2iy3lipXQo
To claim this, I am signing this object:
preset: psr2 | |
risky: false | |
enabled: | |
- short_array_syntax | |
- align_equals | |
- align_double_arrow | |
finder: |
I hereby claim:
To claim this, I am signing this object:
<?php | |
$string= "5 9 2 8 | |
9 4 7 3 | |
3 8 6 5"; | |
$rows = explode("\n", $string); | |
$checksum1 = $checksum2= 0; | |
foreach ($rows as $row) { | |
$row = explode("\t", $row); | |
$checksum1 += (max($row) - min($row)); |
<?php | |
$strInput = "1212"; | |
$arrInput = str_split($strInput); | |
function calc($arrInput, $steps = 1) | |
{ | |
$count = 0; | |
foreach ($arrInput as $key => $value) { | |
$next = $key + $steps; | |
$arrCnt = count($arrInput) - 1; |