test2 - PHP Online

Form of PHP Sandbox

Enter Your PHP code here for testing/debugging in the Online PHP Sandbox. As in the usual PHP files, you can also add HTML, but do not forget to add the tag <?php in the places where the PHP script should be executed.



Your result can be seen below.

Result of php executing





Full code of test2.php

  1. <?php
  2.  
  3. /*
  4. This is our digit for tranformation
  5. */
  6. $inputDigit = 19;
  7.  
  8.  
  9. //$numbers = Array(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);
  10. $alpha = range('A', 'Z');
  11.  
  12. if ($inputDigit < 28) {
  13.    $inputDigit = ($inputDigit % 36) - 1;
  14. } else {
  15.    $inputDigit = (($inputDigit / 36 ) - 1;
  16. }
  17.  
  18. echo $inputDigit.'<br/>';
  19. echo ($alpha[$inputDigit]);
  20.  
  21.  
File Description
  • test2
  • PHP Code
  • 11 Sep-2022
  • 384 Bytes
You can Share it: