Created
August 29, 2013 05:41
-
-
Save Arakaki/6374595 to your computer and use it in GitHub Desktop.
zip.phpのサンプル
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| include './Functional/_import.php'; | |
| use Functional as F; | |
| $resutl1 = Functional\zip( | |
| array('one', 'two', 'three'), | |
| array(1, 2, 3), | |
| array("いち","に","さん"), | |
| array("一","二","三")); | |
| var_dump($resutl1); | |
| $resutl2 = Functional\zip( | |
| array('one', 'two', 'three'), | |
| array(1, 2, 3), | |
| array("いち","に","さん"), | |
| array("一","二","三"), | |
| function($eng, $num,$jp,$kanji) { | |
| return "eng[$eng] : num[$num] : jp[$jp] : kanji[$kanji]"; | |
| } | |
| ); | |
| var_dump($resutl2); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment