<?php
$blankarray = array (
0 =>
array (
'day' => '01/08/2019',
'totalprice' => 585.00
),
1 =>
array (
'day' => '02/08/2019',
'totalprice' => 585.00
),
2 =>
array (
'day' => '03/08/2019',
'totalprice' => 585.00
),
3 =>
array (
'day' => '04/08/2019',
'totalprice' => 585.00
),
4 =>
array (
'day' => '05/08/2019',
'totalprice' => 585.00
),
5 =>
array (
'day' => '06/08/2019',
'totalprice' => 585.00
),
6 =>
array (
'day' => '07/08/2019',
'totalprice' => 585.00
),
7 =>
array (
'day' => '08/08/2019',
'totalprice' => 585.00
),
8 =>
array (
'day' => '09/08/2019',
'totalprice' => 585.00
),
9 =>
array (
'day' => '10/08/2019',
'totalprice' => 585.00
),
10 =>
array (
'day' => '11/08/2019',
'totalprice' => 585.00
),
11 =>
array (
'day' => '12/08/2019',
'totalprice' => 585.00
),
12 =>
array (
'day' => '13/08/2019',
'totalprice' => 585.00
),
13 =>
array (
'day' => '14/08/2019',
'totalprice' => 585.00
),
14 =>
array (
'day' => '15/08/2019',
'totalprice' => 585.00
),
15 =>
array (
'day' => '16/08/2019',
'totalprice' => 585.00
),
16 =>
array (
'day' => '17/08/2019',
'totalprice' => 585.00
),
17 =>
array (
'day' => '18/08/2019',
'totalprice' => 585.00
),
18 =>
array (
'day' => '19/08/2019',
'totalprice' => 585.00
),
19 =>
array (
'day' => '20/08/2019',
'totalprice' => 585.00
),
20 =>
array (
'day' => '21/08/2019',
'totalprice' => 585.00
),
21 =>
array (
'day' => '22/08/2019',
'totalprice' => 585.00
),
22 =>
array (
'day' => '23/08/2019',
'totalprice' => 585.00
),
23 =>
array (
'day' => '24/08/2019',
'totalprice' => 585.00
),
24 =>
array (
'day' => '25/08/2019',
'totalprice' => 585.00
),
25 =>
array (
'day' => '26/08/2019',
'totalprice' => 585.00
),
26 =>
array (
'day' => '27/08/2019',
'totalprice' => 585.00
),
27 =>
array (
'day' => '28/08/2019',
'totalprice' => 585.00
),
28 =>
array (
'day' => '29/08/2019',
'totalprice' => 585.00
),
29 =>
array (
'day' => '30/08/2019',
'totalprice' => 585.00
),
30 =>
array (
'day' => '31/08/2019',
'totalprice' => 585.00
),
31 =>
array (
'day' => '01/09/2019',
'totalprice' => 410.00
),
32 =>
array (
'day' => '02/09/2019',
'totalprice' => 410.00
),
33 =>
array (
'day' => '03/09/2019',
'totalprice' => 0.00
),
34 =>
array (
'day' => '04/09/2019',
'totalprice' => 0.00
),
35 =>
array (
'day' => '05/09/2019',
'totalprice' => 0.00
),
36 =>
array (
'day' => '06/09/2019',
'totalprice' => 0.00
),
37 =>
array (
'day' => '07/09/2019',
'totalprice' => 0.00
),
38 =>
array (
'day' => '08/09/2019',
'totalprice' => 0.00
),
39 =>
array (
'day' => '09/09/2019',
'totalprice' => 0.00
),
40 =>
array (
'day' => '10/09/2019',
'totalprice' => 0.00
),
41 =>
array (
'day' => '11/09/2019',
'totalprice' => 0.00
),
42 =>
array (
'day' => '12/09/2019',
'totalprice' => 0.00
),
43 =>
array (
'day' => '13/09/2019',
'totalprice' => 0.00
),
44 =>
array (
'day' => '14/09/2019',
'totalprice' => 0.00
),
45 =>
array (
'day' => '15/09/2019',
'totalprice' => 0.00
),
46 =>
array (
'day' => '16/09/2019',
'totalprice' => 0.00
),
47 =>
array (
'day' => '17/09/2019',
'totalprice' => 410.00
),
48 =>
array (
'day' => '18/09/2019',
'totalprice' => 410.00
),
49 =>
array (
'day' => '19/09/2019',
'totalprice' => 410.00
),
50 =>
array (
'day' => '20/09/2019',
'totalprice' => 410.00
),
51 =>
array (
'day' => '21/09/2019',
'totalprice' => 410.00
),
52 =>
array (
'day' => '22/09/2019',
'totalprice' => 410.00
),
53 =>
array (
'day' => '23/09/2019',
'totalprice' => 410.00
),
54 =>
array (
'day' => '24/09/2019',
'totalprice' => 410.00
),
55 =>
array (
'day' => '25/09/2019',
'totalprice' => 410.00
),
56 =>
array (
'day' => '26/09/2019',
'totalprice' => 410.00
),
57 =>
array (
'day' => '27/09/2019',
'totalprice' => 410.00
),
58 =>
array (
'day' => '28/09/2019',
'totalprice' => 410.00
),
59 =>
array (
'day' => '29/09/2019',
'totalprice' => 410.00
),
60 =>
array (
'day' => '30/09/2019',
'totalprice' => 410.00
),
61 =>
array (
'day' => '01/10/2019',
'totalprice' => 235.00
),
62 =>
array (
'day' => '02/10/2019',
'totalprice' => 235.00
),
63 =>
array (
'day' => '03/10/2019',
'totalprice' => 235.00
),
64 =>
array (
'day' => '04/10/2019',
'totalprice' => 235.00
),
65 =>
array (
'day' => '05/10/2019',
'totalprice' => 235.00
),
66 =>
array (
'day' => '06/10/2019',
'totalprice' => 235.00
),
67 =>
array (
'day' => '07/10/2019',
'totalprice' => 235.00
),
68 =>
array (
'day' => '08/10/2019',
'totalprice' => 235.00
),
69 =>
array (
'day' => '09/10/2019',
'totalprice' => 235.00
),
70 =>
array (
'day' => '10/10/2019',
'totalprice' => 235.00
),
71 =>
array (
'day' => '11/10/2019',
'totalprice' => 235.00
),
72 =>
array (
'day' => '12/10/2019',
'totalprice' => 235.00
),
73 =>
array (
'day' => '13/10/2019',
'totalprice' => 235.00
),
74 =>
array (
'day' => '14/10/2019',
'totalprice' => 235.00
),
75 =>
array (
'day' => '15/10/2019',
'totalprice' => 235.00
),
76 =>
array (
'day' => '16/10/2019',
'totalprice' => 235.00
),
77 =>
array (
'day' => '17/10/2019',
'totalprice' => 235.00
),
78 =>
array (
'day' => '18/10/2019',
'totalprice' => 235.00
),
79 =>
array (
'day' => '19/10/2019',
'totalprice' => 235.00
),
80 =>
array (
'day' => '20/10/2019',
'totalprice' => 235.00
),
81 =>
array (
'day' => '21/10/2019',
'totalprice' => 235.00
),
82 =>
array (
'day' => '22/10/2019',
'totalprice' => 235.00
),
83 =>
array (
'day' => '23/10/2019',
'totalprice' => 235.00
),
84 =>
array (
'day' => '24/10/2019',
'totalprice' => 235.00
),
85 =>
array (
'day' => '25/10/2019',
'totalprice' => 235.00
),
86 =>
array (
'day' => '26/10/2019',
'totalprice' => 235.00
),
87 =>
array (
'day' => '27/10/2019',
'totalprice' => 235.00
),
88 =>
array (
'day' => '28/10/2019',
'totalprice' => 235.00
),
89 =>
array (
'day' => '29/10/2019',
'totalprice' => 235.00
),
90 =>
array (
'day' => '30/10/2019',
'totalprice' => 235.00
),
91 =>
array (
'day' => '31/10/2019',
'totalprice' => 235.00
)
);
$previousprice = -1;
$thisprice = -1;
$nextprice = $blankarray[0]['totalprice'];
$c = count($blankarray);
for ($i = 0; $i < $c; $i++) {
$previousprice = $thisprice;
$thisprice = $nextprice;
$nextprice = ($i == $c - 1) ? -1 : $blankarray[$i+1]['totalprice'];
if ($previousprice == 0 || $thisprice == 0 || $nextprice == 0) continue;
if ($thisprice != $previousprice) {
echo '<br>'.$blankarray[$i]['day'];
}
if ($thisprice != $nextprice) {
echo '<br>'.$blankarray[$i]['day'];
echo '</br><font color="green"> <b>'.$blankarray[$i]['totalprice'].'</b></font>' . "\n";
}
}
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 42) Position 1 = 50
Branch analysis from position: 50
2 jumps found. (Code = 44) Position 1 = 52, Position 2 = 10
Branch analysis from position: 52
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 10
2 jumps found. (Code = 43) Position 1 = 15, Position 2 = 17
Branch analysis from position: 15
1 jumps found. (Code = 42) Position 1 = 21
Branch analysis from position: 21
2 jumps found. (Code = 47) Position 1 = 24, Position 2 = 26
Branch analysis from position: 24
2 jumps found. (Code = 47) Position 1 = 27, Position 2 = 29
Branch analysis from position: 27
2 jumps found. (Code = 43) Position 1 = 30, Position 2 = 31
Branch analysis from position: 30
1 jumps found. (Code = 42) Position 1 = 49
Branch analysis from position: 49
2 jumps found. (Code = 44) Position 1 = 52, Position 2 = 10
Branch analysis from position: 52
Branch analysis from position: 10
Branch analysis from position: 31
2 jumps found. (Code = 43) Position 1 = 33, Position 2 = 37
Branch analysis from position: 33
2 jumps found. (Code = 43) Position 1 = 39, Position 2 = 49
Branch analysis from position: 39
2 jumps found. (Code = 44) Position 1 = 52, Position 2 = 10
Branch analysis from position: 52
Branch analysis from position: 10
Branch analysis from position: 49
Branch analysis from position: 37
Branch analysis from position: 29
Branch analysis from position: 26
Branch analysis from position: 17
2 jumps found. (Code = 47) Position 1 = 24, Position 2 = 26
Branch analysis from position: 24
Branch analysis from position: 26
filename: /in/39OTA
function name: (null)
number of ops: 53
compiled vars: !0 = $blankarray, !1 = $previousprice, !2 = $thisprice, !3 = $nextprice, !4 = $c, !5 = $i
line #* E I O op fetch ext return operands
-------------------------------------------------------------------------------------
2 0 E > ASSIGN !0, <array>
464 1 ASSIGN !1, -1
465 2 ASSIGN !2, -1
466 3 FETCH_DIM_R ~9 !0, 0
4 FETCH_DIM_R ~10 ~9, 'totalprice'
5 ASSIGN !3, ~10
467 6 COUNT ~12 !0
7 ASSIGN !4, ~12
468 8 ASSIGN !5, 0
9 > JMP ->50
469 10 > ASSIGN !1, !2
470 11 ASSIGN !2, !3
471 12 SUB ~17 !4, 1
13 IS_EQUAL !5, ~17
14 > JMPZ ~18, ->17
15 > QM_ASSIGN ~19 -1
16 > JMP ->21
17 > ADD ~20 !5, 1
18 FETCH_DIM_R ~21 !0, ~20
19 FETCH_DIM_R ~22 ~21, 'totalprice'
20 QM_ASSIGN ~19 ~22
21 > ASSIGN !3, ~19
472 22 IS_EQUAL ~24 !1, 0
23 > JMPNZ_EX ~24 ~24, ->26
24 > IS_EQUAL ~25 !2, 0
25 BOOL ~24 ~25
26 > > JMPNZ_EX ~24 ~24, ->29
27 > IS_EQUAL ~26 !3, 0
28 BOOL ~24 ~26
29 > > JMPZ ~24, ->31
30 > > JMP ->49
473 31 > IS_NOT_EQUAL !2, !1
32 > JMPZ ~27, ->37
474 33 > FETCH_DIM_R ~28 !0, !5
34 FETCH_DIM_R ~29 ~28, 'day'
35 CONCAT ~30 '%3Cbr%3E', ~29
36 ECHO ~30
476 37 > IS_NOT_EQUAL !2, !3
38 > JMPZ ~31, ->49
477 39 > FETCH_DIM_R ~32 !0, !5
40 FETCH_DIM_R ~33 ~32, 'day'
41 CONCAT ~34 '%3Cbr%3E', ~33
42 ECHO ~34
478 43 FETCH_DIM_R ~35 !0, !5
44 FETCH_DIM_R ~36 ~35, 'totalprice'
45 CONCAT ~37 '%3C%2Fbr%3E%3Cfont+color%3D%22green%22%3E+%3Cb%3E', ~36
46 CONCAT ~38 ~37, '%3C%2Fb%3E%3C%2Ffont%3E'
47 CONCAT ~39 ~38, '%0A'
48 ECHO ~39
468 49 > PRE_INC !5
50 > IS_SMALLER !5, !4
51 > JMPNZ ~41, ->10
480 52 > > RETURN 1
Generated using Vulcan Logic Dumper, using php 8.0.0
preferences:
180.12 ms | 1403 KiB | 13 Q