3v4l.org

run code in 300+ PHP versions simultaneously
<?php $dpprice = file_get_contents("https://api.coinmarketcap.com/v1/ticker/digitalprice/", true); $price= json_decode($dpprice); $payamt =$price[0]->price_usd; $paypercent = (1/$payamt); $amtdue= $paypercent*5; $amtdue = number_format((float)$amtdue, 4, '.', ''); ?>
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/9XBPg
function name:  (null)
number of ops:  25
compiled vars:  !0 = $dpprice, !1 = $price, !2 = $payamt, !3 = $paypercent, !4 = $amtdue
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   INIT_FCALL                                               'file_get_contents'
          1        SEND_VAL                                                 'https%3A%2F%2Fapi.coinmarketcap.com%2Fv1%2Fticker%2Fdigitalprice%2F'
          2        SEND_VAL                                                 <true>
          3        DO_ICALL                                         $5      
          4        ASSIGN                                                   !0, $5
    4     5        INIT_FCALL                                               'json_decode'
          6        SEND_VAR                                                 !0
          7        DO_ICALL                                         $7      
          8        ASSIGN                                                   !1, $7
    5     9        FETCH_DIM_R                                      ~9      !1, 0
         10        FETCH_OBJ_R                                      ~10     ~9, 'price_usd'
         11        ASSIGN                                                   !2, ~10
    6    12        DIV                                              ~12     1, !2
         13        ASSIGN                                                   !3, ~12
    7    14        MUL                                              ~14     !3, 5
         15        ASSIGN                                                   !4, ~14
    8    16        INIT_FCALL                                               'number_format'
         17        CAST                                          5  ~16     !4
         18        SEND_VAL                                                 ~16
         19        SEND_VAL                                                 4
         20        SEND_VAL                                                 '.'
         21        SEND_VAL                                                 ''
         22        DO_ICALL                                         $17     
         23        ASSIGN                                                   !4, $17
   11    24      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
138.01 ms | 1012 KiB | 16 Q