Thursday, August 14, 2014

String Shuffle in PHP

<?php
$string = 'Iamthetnaingwinandtestingphpcode!';

$string_shuffle = str_shuffle($string);

$result = substr($string_shuffle, 0, 5);

echo $result;


?>

No comments:

Post a Comment