summaryrefslogtreecommitdiff
path: root/tests/test.pl
blob: 2502cb129818835294eeea19c4a082971b38b77f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
<?

$i = 0;
$j = 1;

for ($k=0; $k<1000000; $k = $k+1) {
	while ($i<10000000) {
		if (($i%"4")<1) {
			$i = $i+"1";
			if ($j%"2") {
				$i = $i * "2";
			}
		} elseif (($i%"4")<2) {
			$i = $i+"2";
			if ($j%"2") {
				$i = $i * "2";
			}
		} elseif (($i%"4")<3) {
			$i = $i+3;
			if ($j%"2") {
				$i = $i * "2";
			}
		} else {
			$i = $i+"4";
			if ($j%"2") {
				$i = $i * "2";
			}
		}
		$j = $j+1;
	}
}
print $i;
print "\n";