note 94728 added to function.chunk-split

From: Date: Fri, 20 Nov 2009 17:10:11 +0000
Subject: note 94728 added to function.chunk-split
Groups: php.notes 
Request: Send a blank email to php-notes+get-163129@lists.php.net to get a copy of this message
//I've found this quite useful for simulating various kinds of shuffles with cards. //It is humorous but can imitate multiple deck cuts and other (imperfectly) random events. function truffle_shuffle($body, $chunklen = 76, $end = "\r\n") { $chunk = chunk_split($body, $chunklen, "-=blender=-"); $truffle = explode("-=blender=-",$chunk); $shuffle = shuffle($truffle); $huknc = implode($end,$shuffle); return $huknc; } ---- Server IP: 69.147.83.197 Probable Submitter: 12.88.155.214 ---- Manual Page -- http://www.php.net/manual/en/function.chunk-split.php Edit -- https://master.php.net/note/edit/94728 Del: integrated -- https://master.php.net/note/delete/94728/integrated Del: useless -- https://master.php.net/note/delete/94728/useless Del: bad code -- https://master.php.net/note/delete/94728/bad+code Del: spam -- https://master.php.net/note/delete/94728/spam Del: non-english -- https://master.php.net/note/delete/94728/non-english Del: in docs -- https://master.php.net/note/delete/94728/in+docs Del: other reasons-- https://master.php.net/note/delete/94728 Reject -- https://master.php.net/note/reject/94728 Search -- https://master.php.net/manage/user-notes.php

« previous php.notes (#163129) next »