$('.link').click(function() {
let url = $(this).data('url');
url = `side/${url}.html`;
...
}
DPS * N = (NormalDamage + CritDamage) * AttackSpeed * N
- (NormalDamage + CritDamage)
+ (NormalDamage + CritDamage) * SuperDamageMultiplier
= (NormalDamage + CritDamage) * (AttackSpeed * N - 1 + SuperDamageMultiplier)
DPS = (NormalDamage + CritDamage) * (AttackSpeed + (SuperDamageMultiplier - 1) / N)
A form control is disabled if any of the following conditions are met:
1. The element is a button, input, select, or textarea element, and the disabled attribute is specified on this element (regardless of its value).
function intervals($arr) {
$start = -1;
$end = -1;
$result = [];
foreach ($arr as $val) {
if ($start === -1) {
$start = $val;
$end = $val;
} elseif ($val === $end + 1) {
$end = $val;
} else {
$result[] = ['start' => $start, 'end' => $end];
$start = $val;
$end = $val;
}
}
if ($start !== -1) {
$result[] = ['start' => $start, 'end' => $end];
}
return $result;
}
print_r(intervals([0,1,2,3,6,7,8,9,12,13,14,15]));
// Array (
// [0] => Array (
// [start] => 0
// [end] => 3
// )
// [1] => Array (
// [start] => 6
// [end] => 9
// )
// [2] => Array (
// [start] => 12
// [end] => 15
// )
// )