[ create a new paste ] login | about

Link: http://codepad.org/9rOYS730    [ raw code | output | fork ]

PHP, pasted on Jan 2:
1
2
3
4
5
6
7
8
9
10
11
<?php
 $replacement = array(0 => '#', 5 => '=', 7 => '#', 9 => '=');
  krsort($replacement);
  
  $str = "ABCDEFGHIJK";
    
    foreach($replacement as $position => $rep) {
        $str = substr_replace($str, $rep, $position, 0);
    }
  
  echo $str;


Output:
1
#ABCDE=FG#HI=JK


Create a new paste based on this one


Comments: