Completed
Push — master ( 12550f...36b37a )
by hook
02:10
created
work2.php 1 patch
Spacing   +11 added lines, -11 removed lines patch added patch discarded remove patch
@@ -7,7 +7,7 @@  discard block
 block discarded – undo
7 7
  */
8 8
 
9 9
 
10
-class Table{
10
+class Table {
11 11
     public function getuser()
12 12
     {
13 13
         return "ok";
@@ -20,27 +20,27 @@  discard block
 block discarded – undo
20 20
         echo "class find\r\n";
21 21
 
22 22
         $t1 = microtime(true);
23
-        foreach (range(1,500) as $a){
23
+        foreach (range(1, 500) as $a) {
24 24
             $func = "get".$field;
25
-            if (is_callable([$this,$func])) {
26
-                call_user_func([$this,$func]);
25
+            if (is_callable([ $this, $func ])) {
26
+                call_user_func([ $this, $func ]);
27 27
             }
28 28
         }
29 29
 
30
-        var_dump(microtime(true)-$t1);
30
+        var_dump(microtime(true) - $t1);
31 31
 
32 32
 
33 33
 
34 34
         echo "array find\r\n";
35 35
         $t1 = microtime(true);
36
-        foreach (range(1,500) as $a) {
37
-            $a = ['set.user' => 'getuser', 'get.user' => 'getuser'];
38
-            $func = 'set.' . $field;
39
-            if (isset($a[$func])) {
40
-                call_user_func([$this, $a[$func]]);
36
+        foreach (range(1, 500) as $a) {
37
+            $a = [ 'set.user' => 'getuser', 'get.user' => 'getuser' ];
38
+            $func = 'set.'.$field;
39
+            if (isset($a[ $func ])) {
40
+                call_user_func([ $this, $a[ $func ] ]);
41 41
             }
42 42
         }
43
-        var_dump(microtime(true)-$t1);
43
+        var_dump(microtime(true) - $t1);
44 44
     }
45 45
 }
46 46
 
Please login to merge, or discard this patch.