3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $uuid = sprintf('%04x%04x%04x%04x%04x%04x%04x%04x', // 32 bits for "time_low" mt_rand(0, 0xffff), mt_rand(0, 0xffff), // 16 bits for "time_mid" mt_rand(0, 0xffff), // 16 bits for "time_hi_and_version", // four most significant bits holds version number 4 mt_rand(0, 0x0fff) | 0x4000, // 16 bits, 8 bits for "clk_seq_hi_res", // 8 bits for "clk_seq_low", // two most significant bits holds zero and one // for variant DCE1.1 mt_rand(0, 0x3fff) | 0x8000, // 48 bits for "node" mt_rand(0, 0xffff), mt_rand(0, 0xffff), mt_rand(0, 0xffff) ); $packedUuid = pack('H*', $uuid); $unpackedUuid = unpack('H*', $packedUuid)[1]; echo $uuid . PHP_EOL; echo strlen($uuid) . PHP_EOL; echo $packedUuid . PHP_EOL; echo strlen($packedUuid) . PHP_EOL; echo $unpackedUuid . PHP_EOL; echo strlen($unpackedUuid) . PHP_EOL;
Output for 7.2.0
ededd4cd17264f239eef59ecd4650441 32 ����&O#��Y��eA 16 ededd4cd17264f239eef59ecd4650441 32
Output for 7.1.7
50c0e7926d154b7f99054f1e2269bf50 32 P��mK�O"i�P 16 50c0e7926d154b7f99054f1e2269bf50 32
Output for 7.1.6
045ad3c351494ee79f07ac205bdf81c7 32 Z��QIN�� [߁� 16 045ad3c351494ee79f07ac205bdf81c7 32
Output for 7.1.5
5156ed229e904b54ad0e4bcc21341c05 32 QV�"��KT�K�!4 16 5156ed229e904b54ad0e4bcc21341c05 32
Output for 7.1.0
144eb48042fc459298b50341eada40c9 32 N��B�E���A��@� 16 144eb48042fc459298b50341eada40c9 32
Output for 7.0.20
abe9370d04114800b41c279bc05b3060 32 ��7 H�'��[0` 16 abe9370d04114800b41c279bc05b3060 32
Output for 7.0.14
60a5841c4bc649e78a29a1d483af35c1 32 `��K�I�)�ԃ�5� 16 60a5841c4bc649e78a29a1d483af35c1 32
Output for 7.0.6
bbe5732e147b4ddaa85586f235aea2e6 32 ��s.{MڨU��5��� 16 bbe5732e147b4ddaa85586f235aea2e6 32
Output for 7.0.5
1eb13e4b40814d3f82422a5b6adc1c9b 32 �>K@�M?�B*[j�� 16 1eb13e4b40814d3f82422a5b6adc1c9b 32
Output for 7.0.4
07efc5cdfb6c4e4d8b7d73a1e9e04623 32 ���lNM�}s���F# 16 07efc5cdfb6c4e4d8b7d73a1e9e04623 32
Output for 7.0.3
180cc46ffab240a9bb3f67afa347f0d7 32  �o��@��?g��G�� 16 180cc46ffab240a9bb3f67afa347f0d7 32
Output for 7.0.2
8b7e5b3e70ee4083b0eba2d05cbf7656 32 �~[>p�@����\�vV 16 8b7e5b3e70ee4083b0eba2d05cbf7656 32
Output for 7.0.1
9a6b27ca5d7b4f6ca98bd1cd8cbaddf1 32 �k'�]{Ol���͌��� 16 9a6b27ca5d7b4f6ca98bd1cd8cbaddf1 32
Output for 7.0.0
3ffbe12160f948ce8b1c844de5db823a 32 ?��!`�H΋�M�ۂ: 16 3ffbe12160f948ce8b1c844de5db823a 32
Output for 5.6.28
29a3654d05914e52b51fe326a2757dc2 32 )�eM�NR��&�u}� 16 29a3654d05914e52b51fe326a2757dc2 32
Output for 5.6.21
023c7f8ccb1e481b8852a9f845bf942d 32 <��H�R��E��- 16 023c7f8ccb1e481b8852a9f845bf942d 32
Output for 5.6.20
ab97d92133c241a9b412a73807d524d1 32 ���!3�A���8�$� 16 ab97d92133c241a9b412a73807d524d1 32
Output for 5.6.19
0bee08532b2f4058bf9a03bc2cd8268f 32 �S+/@X���,�&� 16 0bee08532b2f4058bf9a03bc2cd8268f 32
Output for 5.6.18
95465460098c44aab99d42ad2e5a58a8 32 �FT` �D���B�.ZX� 16 95465460098c44aab99d42ad2e5a58a8 32
Output for 5.6.17
96e7f4729ac343df8c943215b8cc9e15 32 ���r��Cߌ�2�̞ 16 96e7f4729ac343df8c943215b8cc9e15 32
Output for 5.6.16
b4bdc1cce42c4043bc6dcb08bbd89e7b 32 �����,@C�m��؞{ 16 b4bdc1cce42c4043bc6dcb08bbd89e7b 32
Output for 5.6.15
3426f1d53aec430b9d0f4d5cf1e3daa7 32 4&��:�C �M\��ڧ 16 3426f1d53aec430b9d0f4d5cf1e3daa7 32
Output for 5.6.14
b65b45d8977b4fabaf8635751c514064 32 �[Eؗ{O���5uQ@d 16 b65b45d8977b4fabaf8635751c514064 32
Output for 5.6.13
d7e874e64d23491cb62f5dd9fdbd3ba1 32 ��t�M#I�/]��;� 16 d7e874e64d23491cb62f5dd9fdbd3ba1 32
Output for 5.6.12
3a873c4c9f3c48c4bb9385df71f75f48 32 :�<L�<HĻ���q�_H 16 3a873c4c9f3c48c4bb9385df71f75f48 32
Output for 5.6.11
76a7d1ad909a41e1aef86e200ee8b6ba 32 v�ѭ��A�n 趺 16 76a7d1ad909a41e1aef86e200ee8b6ba 32
Output for 5.6.10
85b8d09a92aa4a35854e223c5d3f3275 32 ����J5�N"<]?2u 16 85b8d09a92aa4a35854e223c5d3f3275 32
Output for 5.6.9
d3ef4767a7074e7ca679caec2a59def4 32 ��Gg�N|�y��*Y�� 16 d3ef4767a7074e7ca679caec2a59def4 32
Output for 5.6.8
779878ec745f4afea6628475d9823141 32 w�x�t_J��b�uق1A 16 779878ec745f4afea6628475d9823141 32
Output for 5.6.7
d114429faa8645d8b9a8cfd864f6d582 32 �B���Eع���d�Ղ 16 d114429faa8645d8b9a8cfd864f6d582 32
Output for 5.5.35
e616e606e3f244ca8004fe42583da17a 32 ����Dʀ�BX=�z 16 e616e606e3f244ca8004fe42583da17a 32
Output for 5.5.34
e278eff2a94248978d406e450206c5a4 32 �x��BH��@nEŤ 16 e278eff2a94248978d406e450206c5a4 32
Output for 5.5.33
275f3134e27a4b8cb925aee10c5f3bcc 32 '_14�zK��%�� _;� 16 275f3134e27a4b8cb925aee10c5f3bcc 32
Output for 5.5.32
2099f925efb046228ad0ef997b4a2494 32 ��%�F"���{J$� 16 2099f925efb046228ad0ef997b4a2494 32
Output for 5.5.31
c9bcb99774f34758b41fe0271ad0e096 32 ɼ��t�GX��'�� 16 c9bcb99774f34758b41fe0271ad0e096 32
Output for 5.5.30
1f67ba0585454ea8b9ff66ba4ae69bbe 32 g��EN���f�J曾 16 1f67ba0585454ea8b9ff66ba4ae69bbe 32
Output for 5.5.29
1b98f73108b141be910bdbf233363dcb 32 ��1�A�� ��36=� 16 1b98f73108b141be910bdbf233363dcb 32
Output for 5.5.28
0065d370bf24490a87fa8ae00e027212 32 e�p�$I ����r 16 0065d370bf24490a87fa8ae00e027212 32
Output for 5.5.27
2677030abc944339b7ba0151231463a8 32 &w ��C9��Q#c� 16 2677030abc944339b7ba0151231463a8 32
Output for 5.5.26
705a040fc70b486cb76d861f1118d28d 32 pZ� Hl�m�ҍ 16 705a040fc70b486cb76d861f1118d28d 32
Output for 5.5.25
6baf9c5511c94decaaaf6fab902b6df5 32 k��U�M쪯o��+m� 16 6baf9c5511c94decaaaf6fab902b6df5 32
Output for 5.5.24
9439ec37380745699f10084fce0089f0 32 �9�78Ei�O��� 16 9439ec37380745699f10084fce0089f0 32
Output for 5.4.45
c98b2231d3354c768cedffd998736c78 32 ɋ"1�5Lv��٘slx 16 c98b2231d3354c768cedffd998736c78 32
Output for 5.4.44
cb03bd24d1c248178c2cce28641f105d 32 ��$��H�,�(d] 16 cb03bd24d1c248178c2cce28641f105d 32
Output for 5.4.43
cb5c40eb7f394c70bedcf431ef1f8fb9 32 �\@�9Lp���1��� 16 cb5c40eb7f394c70bedcf431ef1f8fb9 32
Output for 5.4.42
2626a378000d4000a3b7f4f5351a88b9 32 &&�x @���5�� 16 2626a378000d4000a3b7f4f5351a88b9 32
Output for 5.4.41
7d72844d51f5498e9f5741870ee6e7b4 32 }r�MQ�I��WA��� 16 7d72844d51f5498e9f5741870ee6e7b4 32
Output for 5.4.40
6f592a0f965d46e8902e9d7b4a629bc4 32 oY*�]F�.�{Jb�� 16 6f592a0f965d46e8902e9d7b4a629bc4 32
Output for 5.4.39
48e7613be79a4fa19e68d4ad0b91b038 32 H�a;�O��hԭ ��8 16 48e7613be79a4fa19e68d4ad0b91b038 32
Output for 5.4.38
92076d2ef16d4a96853e3c5396f73519 32 �m.�mJ��><S��5 16 92076d2ef16d4a96853e3c5396f73519 32
Output for 5.4.37
ba19191d3bae47d6acb4c6855f355934 32 �;�G֬�ƅ_5Y4 16 ba19191d3bae47d6acb4c6855f355934 32
Output for 5.4.36
afa8fd2c9b1f4befbf29ed8ae47bce3d 32 ���,�K�)��{�= 16 afa8fd2c9b1f4befbf29ed8ae47bce3d 32
Output for 5.4.35
bc6b6583e21b4438b78a13cb546e3004 32 �ke��D8���Tn0 16 bc6b6583e21b4438b78a13cb546e3004 32
Output for 5.4.34
98869f58afc442b3a683e8e8e1c97ca9 32 ���X��B�������|� 16 98869f58afc442b3a683e8e8e1c97ca9 32
Output for 5.4.32
76ab245625f04abb86ac9a323a0a55c7 32 v�$V%�J����2: U� 16 76ab245625f04abb86ac9a323a0a55c7 32
Output for 5.4.31
ad730168f29149b499f1855292af9987 32 �sh�I���R���� 16 ad730168f29149b499f1855292af9987 32
Output for 5.4.30
23790fca3141422a8e2a73145ceec8ea 32 #y�1AB*�*s\��� 16 23790fca3141422a8e2a73145ceec8ea 32
Output for 5.4.29
187eb5bf7dde4305926007bf3ea4cfd3 32 ~��}�C�`Ovp6P�>��� 16 187eb5bf7dde4305926007bf3ea4cfd3 32
Output for 5.4.28
31387f57aaaa448ebb70abe2111d3b0a 32 18W��D��p��; 16 31387f57aaaa448ebb70abe2111d3b0a 32
Output for 5.4.27
0613ca0b18604814828893eae6e68af5 32 5.4.27� `H������ 16 0613ca0b18604814828893eae6e68af5 32
Output for 5.4.26
3fb9ea2bed3d474792e5ecde48a64f07 32 ?��+�=GG����H�OOvp6P 16 3fb9ea2bed3d474792e5ecde48a64f07 32
Output for 5.4.25
b01fc36115fc428f8c4efdb1ec38d929 32 ��a�B��N���8�) 16 b01fc36115fc428f8c4efdb1ec38d929 32
Output for 5.4.24
2bf6af54014149a4a6df551af716565b 32 +��TAI���U�V[ 16 2bf6af54014149a4a6df551af716565b 32
Output for 5.4.23
6401d678c73b43868ac2fcbdd158f29c 32 d�x�;C�����X� 16 6401d678c73b43868ac2fcbdd158f29c 32
Output for 5.4.22
b7db1cad71db4bae80aae9df96d757a2 32 ���q�K����ߖ�W� 16 b7db1cad71db4bae80aae9df96d757a2 32
Output for 5.4.21
3296416615c54910b703a5eeb626fea3 32 2�Af�I���&�� 16 3296416615c54910b703a5eeb626fea3 32
Output for 5.4.20
d79f0e8364244f488485918b51b3c231 32 ן�d$OH����Q��1 16 d79f0e8364244f488485918b51b3c231 32
Output for 5.4.19
dd6c452522d8468db044a3c9b76719b3 32 �lE%"�F��D�ɷg� 16 dd6c452522d8468db044a3c9b76719b3 32
Output for 5.4.18
3f35c3bc208c4148ab32e77b9be63f64 32 ?5ü �AH�2�{��?d 16 3f35c3bc208c4148ab32e77b9be63f64 32
Output for 5.4.17
a6fcf83629974266b3f22da666074fd8 32 ���6)�Bf��-�fO� 16 a6fcf83629974266b3f22da666074fd8 32
Output for 5.4.16
163d6ab082ff4647978c47384dee865d 32 =j���FG��G8M�] 16 163d6ab082ff4647978c47384dee865d 32
Output for 5.4.15
2b6350f98f2e42b78f40971d857612be 32 +cP��.B��@��v� 16 2b6350f98f2e42b78f40971d857612be 32
Output for 5.4.14
d8aa44d8e6524156a43b102709f5a280 32 تD��RAV�;' ��� 16 d8aa44d8e6524156a43b102709f5a280 32
Output for 5.4.13
1eede84da33741a58f3b4c5ae702792c 32 ��M�7A��;LZ�y, 16 1eede84da33741a58f3b4c5ae702792c 32
Output for 5.4.12
ccdb737be8254114b1670742384e457a 32 ��s{�%A�gB8NEz 16 ccdb737be8254114b1670742384e457a 32
Output for 5.4.11
15d1d2ce82894a378acc32d30dc9534b 32 ��΂�J7��2� �SK 16 15d1d2ce82894a378acc32d30dc9534b 32
Output for 5.4.10
84db6af61e464cdd979657bb690eeda0 32 ��j�FLݗ�W�i� 16 84db6af61e464cdd979657bb690eeda0 32
Output for 5.4.9
ff3f5ed7225941b8ba5b8b654c18c5a9 32 �?^�"YA��[�eLũ 16 ff3f5ed7225941b8ba5b8b654c18c5a9 32
Output for 5.4.8
16f8c414ceb34a90a10a6a12c25995dd 32 ��γJ�� j�Y�� 16 16f8c414ceb34a90a10a6a12c25995dd 32
Output for 5.4.7
84c0bd356b004fcaaa3450738ffbbb35 32 ���5kOʪ4Ps���5 16 84c0bd356b004fcaaa3450738ffbbb35 32
Output for 5.4.6
c8845e92df674c83a97abcfbe415fff1 32 Ȅ^��gL��z����� 16 c8845e92df674c83a97abcfbe415fff1 32
Output for 5.4.5
ac2b3ba501ac484398c18fd1de3fdfd0 32 �+;��HC�����?�� 16 ac2b3ba501ac484398c18fd1de3fdfd0 32
Output for 5.4.4
06666fb0c1b84aad86cc3aeb11da200d 32 fo���J���:�� 16 06666fb0c1b84aad86cc3aeb11da200d 32
Output for 5.4.3
bd0c80bb2f1b46fe99a63ea87cb6b038 32 � ��/F���>�|��8 16 bd0c80bb2f1b46fe99a63ea87cb6b038 32
Output for 5.4.2
173984d08fc34d3eaea0477f30c93f75 32 9�Џ�M>��G0�?u 16 173984d08fc34d3eaea0477f30c93f75 32
Output for 5.4.1
b7f78970c0e64e6d8a9a6a269d161161 32 ���p��Nm��j&�a 16 b7f78970c0e64e6d8a9a6a269d161161 32
Output for 5.4.0
857a9299300c4b3e998fbd78ac106d63 32 �z��0 K>���x�mc 16 857a9299300c4b3e998fbd78ac106d63 32
Output for 4.4.2 - 4.4.9, 5.1.0 - 5.3.29
Parse error: syntax error, unexpected '[' in /in/Ovp6P on line 21
Process exited with code 255.
Output for 4.3.0 - 4.3.1, 4.3.5 - 4.4.1, 5.0.0 - 5.0.5
Parse error: parse error, unexpected '[' in /in/Ovp6P on line 21
Process exited with code 255.
Output for 4.3.2 - 4.3.4
Parse error: parse error in /in/Ovp6P on line 21
Process exited with code 255.