subreddit stringclasses 7
values | author stringlengths 3 20 | id stringlengths 5 7 | content stringlengths 67 30.4k | score int64 0 140k |
|---|---|---|---|---|
lolphp | ilogik | 2ex6o2 | <|soss|><|sot|>what do you think this will output?<|eot|><|sost|> <?php
$a = array(1, 2, 3, 4, 5, 6);
foreach ($a as $i)
{
switch ($i){
case 1:
case 3:
case 5:
continue;
}
echo $i;
}
This actually caused a bug in production code. Our expectation ... | 49 |
lolphp | HelloAnnyong | ck3sy8q | <|soss|><|sot|>what do you think this will output?<|eot|><|sost|> <?php
$a = array(1, 2, 3, 4, 5, 6);
foreach ($a as $i)
{
switch ($i){
case 1:
case 3:
case 5:
continue;
}
echo $i;
}
This actually caused a bug in production code. Our expectation ... | 30 |
lolphp | smog_alado | ck3y44x | <|soss|><|sot|>what do you think this will output?<|eot|><|sost|> <?php
$a = array(1, 2, 3, 4, 5, 6);
foreach ($a as $i)
{
switch ($i){
case 1:
case 3:
case 5:
continue;
}
echo $i;
}
This actually caused a bug in production code. Our expectation ... | 23 |
lolphp | expugnator3000 | ck3wsl5 | <|soss|><|sot|>what do you think this will output?<|eot|><|sost|> <?php
$a = array(1, 2, 3, 4, 5, 6);
foreach ($a as $i)
{
switch ($i){
case 1:
case 3:
case 5:
continue;
}
echo $i;
}
This actually caused a bug in production code. Our expectation ... | 18 |
lolphp | ilogik | ck3yikb | <|soss|><|sot|>what do you think this will output?<|eot|><|sost|> <?php
$a = array(1, 2, 3, 4, 5, 6);
foreach ($a as $i)
{
switch ($i){
case 1:
case 3:
case 5:
continue;
}
echo $i;
}
This actually caused a bug in production code. Our expectation ... | 14 |
lolphp | tdammers | ck3wc4x | <|soss|><|sot|>what do you think this will output?<|eot|><|sost|> <?php
$a = array(1, 2, 3, 4, 5, 6);
foreach ($a as $i)
{
switch ($i){
case 1:
case 3:
case 5:
continue;
}
echo $i;
}
This actually caused a bug in production code. Our expectation ... | 13 |
lolphp | ilogik | ck3ygxr | <|soss|><|sot|>what do you think this will output?<|eot|><|sost|> <?php
$a = array(1, 2, 3, 4, 5, 6);
foreach ($a as $i)
{
switch ($i){
case 1:
case 3:
case 5:
continue;
}
echo $i;
}
This actually caused a bug in production code. Our expectation ... | 9 |
lolphp | suspiciously_calm | ck484sy | <|soss|><|sot|>what do you think this will output?<|eot|><|sost|> <?php
$a = array(1, 2, 3, 4, 5, 6);
foreach ($a as $i)
{
switch ($i){
case 1:
case 3:
case 5:
continue;
}
echo $i;
}
This actually caused a bug in production code. Our expectation ... | 8 |
lolphp | Banane9 | ck4goel | <|soss|><|sot|>what do you think this will output?<|eot|><|sost|> <?php
$a = array(1, 2, 3, 4, 5, 6);
foreach ($a as $i)
{
switch ($i){
case 1:
case 3:
case 5:
continue;
}
echo $i;
}
This actually caused a bug in production code. Our expectation ... | 6 |
lolphp | ilogik | ck3tkzo | <|soss|><|sot|>what do you think this will output?<|eot|><|sost|> <?php
$a = array(1, 2, 3, 4, 5, 6);
foreach ($a as $i)
{
switch ($i){
case 1:
case 3:
case 5:
continue;
}
echo $i;
}
This actually caused a bug in production code. Our expectation ... | 5 |
lolphp | Banane9 | ck6oaia | <|soss|><|sot|>what do you think this will output?<|eot|><|sost|> <?php
$a = array(1, 2, 3, 4, 5, 6);
foreach ($a as $i)
{
switch ($i){
case 1:
case 3:
case 5:
continue;
}
echo $i;
}
This actually caused a bug in production code. Our expectation ... | 5 |
lolphp | fnzp | 2cb2y0 | <|sols|><|sot|>A group of Facebook developers has decided to break with 20 years of tradition and release a formal specification for the PHP programming language.<|eot|><|sol|>http://www.theregister.co.uk/2014/08/01/php_draft_specification/<|eol|><|eols|><|endoftext|> | 48 |
lolphp | andronikus | cjdz9y4 | <|sols|><|sot|>A group of Facebook developers has decided to break with 20 years of tradition and release a formal specification for the PHP programming language.<|eot|><|sol|>http://www.theregister.co.uk/2014/08/01/php_draft_specification/<|eol|><|sor|>When I heard there wasn't a language spec, at first I was surprise... | 22 |
lolphp | midir | cje425r | <|sols|><|sot|>A group of Facebook developers has decided to break with 20 years of tradition and release a formal specification for the PHP programming language.<|eot|><|sol|>http://www.theregister.co.uk/2014/08/01/php_draft_specification/<|eol|><|sor|>That's like drawing a map of a turd.<|eor|><|eols|><|endoftext|> | 19 |
lolphp | more_exercise | cjegah9 | <|sols|><|sot|>A group of Facebook developers has decided to break with 20 years of tradition and release a formal specification for the PHP programming language.<|eot|><|sol|>http://www.theregister.co.uk/2014/08/01/php_draft_specification/<|eol|><|sor|>I laughed out loud reading the specification for the application o... | 18 |
lolphp | graingert | cjdylyn | <|sols|><|sot|>A group of Facebook developers has decided to break with 20 years of tradition and release a formal specification for the PHP programming language.<|eot|><|sol|>http://www.theregister.co.uk/2014/08/01/php_draft_specification/<|eol|><|soopr|>How will this work?
Facebook developers: Here's your awesome PH... | 18 |
lolphp | maxufimo | cjebykp | <|sols|><|sot|>A group of Facebook developers has decided to break with 20 years of tradition and release a formal specification for the PHP programming language.<|eot|><|sol|>http://www.theregister.co.uk/2014/08/01/php_draft_specification/<|eol|><|sor|>You'd think at some point along the way the Facebook devs would ha... | 17 |
lolphp | allthediamonds | cjdwii8 | <|sols|><|sot|>A group of Facebook developers has decided to break with 20 years of tradition and release a formal specification for the PHP programming language.<|eot|><|sol|>http://www.theregister.co.uk/2014/08/01/php_draft_specification/<|eol|><|sor|>Actually it's pretty well thought. It's a first step, but if you l... | 16 |
lolphp | _vec_ | cjehsyu | <|sols|><|sot|>A group of Facebook developers has decided to break with 20 years of tradition and release a formal specification for the PHP programming language.<|eot|><|sol|>http://www.theregister.co.uk/2014/08/01/php_draft_specification/<|eol|><|sor|>I laughed out loud reading the specification for the application o... | 16 |
lolphp | tdammers | cjdrtl8 | <|sols|><|sot|>A group of Facebook developers has decided to break with 20 years of tradition and release a formal specification for the PHP programming language.<|eot|><|sol|>http://www.theregister.co.uk/2014/08/01/php_draft_specification/<|eol|><|sor|>Lol, "tradition"...<|eor|><|eols|><|endoftext|> | 15 |
lolphp | T3hUb3rK1tten | cje319q | <|sols|><|sot|>A group of Facebook developers has decided to break with 20 years of tradition and release a formal specification for the PHP programming language.<|eot|><|sol|>http://www.theregister.co.uk/2014/08/01/php_draft_specification/<|eol|><|sor|>You'd think at some point along the way the Facebook devs would ha... | 15 |
lolphp | fnzp | cjdvciw | <|sols|><|sot|>A group of Facebook developers has decided to break with 20 years of tradition and release a formal specification for the PHP programming language.<|eot|><|sol|>http://www.theregister.co.uk/2014/08/01/php_draft_specification/<|eol|><|soopr|>How will this work?
Facebook developers: Here's your awesome PH... | 15 |
lolphp | Drainedsoul | cje4lmz | <|sols|><|sot|>A group of Facebook developers has decided to break with 20 years of tradition and release a formal specification for the PHP programming language.<|eot|><|sol|>http://www.theregister.co.uk/2014/08/01/php_draft_specification/<|eol|><|sor|>I laughed out loud reading the specification for the application o... | 14 |
lolphp | polish_niceguy | cjdxpot | <|sols|><|sot|>A group of Facebook developers has decided to break with 20 years of tradition and release a formal specification for the PHP programming language.<|eot|><|sol|>http://www.theregister.co.uk/2014/08/01/php_draft_specification/<|eol|><|sor|>Actually it's pretty well thought. It's a first step, but if you l... | 14 |
lolphp | _vec_ | cjec8mg | <|sols|><|sot|>A group of Facebook developers has decided to break with 20 years of tradition and release a formal specification for the PHP programming language.<|eot|><|sol|>http://www.theregister.co.uk/2014/08/01/php_draft_specification/<|eol|><|sor|>You'd think at some point along the way the Facebook devs would ha... | 10 |
lolphp | ElusiveGuy | cjesxj6 | <|sols|><|sot|>A group of Facebook developers has decided to break with 20 years of tradition and release a formal specification for the PHP programming language.<|eot|><|sol|>http://www.theregister.co.uk/2014/08/01/php_draft_specification/<|eol|><|sor|>Actually it's pretty well thought. It's a first step, but if you l... | 9 |
lolphp | merreborn | cjeckdm | <|sols|><|sot|>A group of Facebook developers has decided to break with 20 years of tradition and release a formal specification for the PHP programming language.<|eot|><|sol|>http://www.theregister.co.uk/2014/08/01/php_draft_specification/<|eol|><|sor|>You'd think at some point along the way the Facebook devs would ha... | 7 |
lolphp | gearvOsh | cjed6mk | <|sols|><|sot|>A group of Facebook developers has decided to break with 20 years of tradition and release a formal specification for the PHP programming language.<|eot|><|sol|>http://www.theregister.co.uk/2014/08/01/php_draft_specification/<|eol|><|soopr|>How will this work?
Facebook developers: Here's your awesome PH... | 7 |
lolphp | merreborn | cjedxi8 | <|sols|><|sot|>A group of Facebook developers has decided to break with 20 years of tradition and release a formal specification for the PHP programming language.<|eot|><|sol|>http://www.theregister.co.uk/2014/08/01/php_draft_specification/<|eol|><|sor|>You'd think at some point along the way the Facebook devs would ha... | 6 |
lolphp | HookahComputer | cjhicut | <|sols|><|sot|>A group of Facebook developers has decided to break with 20 years of tradition and release a formal specification for the PHP programming language.<|eot|><|sol|>http://www.theregister.co.uk/2014/08/01/php_draft_specification/<|eol|><|sor|>I laughed out loud reading the specification for the application o... | 5 |
lolphp | LPanthers | 21z2n6 | <|soss|><|sot|>I'm a newbie and I'm currently learning PHP. Tell me why PHP sucks dick ?<|eot|><|sost|><|eost|><|eoss|><|endoftext|> | 48 |
lolphp | Capaj | cgi0o6o | <|soss|><|sot|>I'm a newbie and I'm currently learning PHP. Tell me why PHP sucks dick ?<|eot|><|sost|><|eost|><|sor|>http://me.veekun.com/blog/2012/04/09/php-a-fractal-of-bad-design/<|eor|><|sor|>From the comments on that article:
>'PHP is the Winchester Mystery House of programming languages. If PHP were a house, th... | 77 |
lolphp | TheBananaKing | cghsvao | <|soss|><|sot|>I'm a newbie and I'm currently learning PHP. Tell me why PHP sucks dick ?<|eot|><|sost|><|eost|><|sor|>http://me.veekun.com/blog/2012/04/09/php-a-fractal-of-bad-design/<|eor|><|eoss|><|endoftext|> | 68 |
lolphp | vytah | cghv65h | <|soss|><|sot|>I'm a newbie and I'm currently learning PHP. Tell me why PHP sucks dick ?<|eot|><|sost|><|eost|><|sor|>Easiest to understand reason? [You'll get paid less.](http://bpodgursky.com/2013/08/21/average-income-per-programming-language/)
I'll explain another reason with an analogy: imagine you want to be an a... | 50 |
lolphp | hahainternet | cghuelz | <|soss|><|sot|>I'm a newbie and I'm currently learning PHP. Tell me why PHP sucks dick ?<|eot|><|sost|><|eost|><|sor|>It does nothing better than anything else. It has bizarre rules, inconsistent naming, impossible exceptions and there's no justification for it.
Perl or Python. Go or Rust. Haskell or Erlang. Those are... | 32 |
lolphp | Serialk | cgm5wae | <|soss|><|sot|>I'm a newbie and I'm currently learning PHP. Tell me why PHP sucks dick ?<|eot|><|sost|><|eost|><|sor|>http://me.veekun.com/blog/2012/04/09/php-a-fractal-of-bad-design/<|eor|><|sor|>Best read [alongside a rebuttal](http://forums.devshed.com/php-development-5/php-fractal-bad-design-hardly-929746.html). Mo... | 25 |
lolphp | hahainternet | cghtes2 | <|soss|><|sot|>I'm a newbie and I'm currently learning PHP. Tell me why PHP sucks dick ?<|eot|><|sost|><|eost|><|sor|>It does nothing better than anything else. It has bizarre rules, inconsistent naming, impossible exceptions and there's no justification for it.
Perl or Python. Go or Rust. Haskell or Erlang. Those are... | 22 |
lolphp | allthediamonds | cgi1xon | <|soss|><|sot|>I'm a newbie and I'm currently learning PHP. Tell me why PHP sucks dick ?<|eot|><|sost|><|eost|><|sor|>PHP doesn't suck. It's the people working on PHP that suck.<|eor|><|sor|>There's some truth to this. PHP does suck, but people working on PHP suck as well. Keep in mind that if you work on a PHP shop, m... | 21 |
lolphp | _vec_ | cgmb0fg | <|soss|><|sot|>I'm a newbie and I'm currently learning PHP. Tell me why PHP sucks dick ?<|eot|><|sost|><|eost|><|sor|>http://me.veekun.com/blog/2012/04/09/php-a-fractal-of-bad-design/<|eor|><|sor|>Best read [alongside a rebuttal](http://forums.devshed.com/php-development-5/php-fractal-bad-design-hardly-929746.html). Mo... | 21 |
lolphp | PasswordIsntHAMSTER | cgi6eif | <|soss|><|sot|>I'm a newbie and I'm currently learning PHP. Tell me why PHP sucks dick ?<|eot|><|sost|><|eost|><|sor|>It does nothing better than anything else. It has bizarre rules, inconsistent naming, impossible exceptions and there's no justification for it.
Perl or Python. Go or Rust. Haskell or Erlang. Those are... | 20 |
lolphp | CornPlanter | cghvgfx | <|soss|><|sot|>I'm a newbie and I'm currently learning PHP. Tell me why PHP sucks dick ?<|eot|><|sost|><|eost|><|sor|>It does nothing better than anything else. It has bizarre rules, inconsistent naming, impossible exceptions and there's no justification for it.
Perl or Python. Go or Rust. Haskell or Erlang. Those are... | 19 |
lolphp | EvilTerran | cgi5iwn | <|soss|><|sot|>I'm a newbie and I'm currently learning PHP. Tell me why PHP sucks dick ?<|eot|><|sost|><|eost|><|sor|>Easiest to understand reason? [You'll get paid less.](http://bpodgursky.com/2013/08/21/average-income-per-programming-language/)
I'll explain another reason with an analogy: imagine you want to be an a... | 18 |
lolphp | hahainternet | cghvztl | <|soss|><|sot|>I'm a newbie and I'm currently learning PHP. Tell me why PHP sucks dick ?<|eot|><|sost|><|eost|><|sor|>It does nothing better than anything else. It has bizarre rules, inconsistent naming, impossible exceptions and there's no justification for it.
Perl or Python. Go or Rust. Haskell or Erlang. Those are... | 18 |
lolphp | PasswordIsntHAMSTER | cgi7040 | <|soss|><|sot|>I'm a newbie and I'm currently learning PHP. Tell me why PHP sucks dick ?<|eot|><|sost|><|eost|><|sor|>It does nothing better than anything else. It has bizarre rules, inconsistent naming, impossible exceptions and there's no justification for it.
Perl or Python. Go or Rust. Haskell or Erlang. Those are... | 16 |
lolphp | Razakel | cgieu36 | <|soss|><|sot|>I'm a newbie and I'm currently learning PHP. Tell me why PHP sucks dick ?<|eot|><|sost|><|eost|><|sor|>PHP is like giving a baby a nailgun. It *can* be used properly, but chances are you'll end up with a bloody mess.<|eor|><|eoss|><|endoftext|> | 15 |
lolphp | allthediamonds | cgi2n4b | <|soss|><|sot|>I'm a newbie and I'm currently learning PHP. Tell me why PHP sucks dick ?<|eot|><|sost|><|eost|><|sor|>PHP doesn't suck. It's the people working on PHP that suck.<|eor|><|sor|>There's some truth to this. PHP does suck, but people working on PHP suck as well. Keep in mind that if you work on a PHP shop, m... | 14 |
lolphp | PasswordIsntHAMSTER | cgi6dwz | <|soss|><|sot|>I'm a newbie and I'm currently learning PHP. Tell me why PHP sucks dick ?<|eot|><|sost|><|eost|><|sor|>Easiest to understand reason? [You'll get paid less.](http://bpodgursky.com/2013/08/21/average-income-per-programming-language/)
I'll explain another reason with an analogy: imagine you want to be an a... | 14 |
lolphp | RedWingate | t8k06 | <|sols|><|sot|>Stop calling them developers ...<|eot|><|sol|>http://i.imgur.com/TeQZQ.jpg<|eol|><|eols|><|endoftext|> | 45 |
lolphp | StrangeWill | c4kik6y | <|sols|><|sot|>Stop calling them developers ...<|eot|><|sol|>http://i.imgur.com/TeQZQ.jpg<|eol|><|sor|>Lots of people make a living doing PHP development, therefore, they are developers. I personally think JavaScript is the crappiest language programmers have to deal with, but I'm not about to strip away "developer" fr... | 16 |
lolphp | droidballoon | c4kijlc | <|sols|><|sot|>Stop calling them developers ...<|eot|><|sol|>http://i.imgur.com/TeQZQ.jpg<|eol|><|sor|>Lots of people make a living doing PHP development, therefore, they are developers. I personally think JavaScript is the crappiest language programmers have to deal with, but I'm not about to strip away "developer" fr... | 12 |
lolphp | Takeoded | z9mp36 | <|soss|><|sot|>socket_set_block() accepts sockets not streams, and socket_set_blocking() accepts streams not sockets.<|eot|><|sost|>compare [socket_set_block()](https://www.php.net/manual/en/function.socket-set-block) vs [socket_set_blocking()](https://www.php.net/manual/en/function.socket-set-blocking) , i just used t... | 47 |
lolphp | modestlife | iyhn2kr | <|soss|><|sot|>socket_set_block() accepts sockets not streams, and socket_set_blocking() accepts streams not sockets.<|eot|><|sost|>compare [socket_set_block()](https://www.php.net/manual/en/function.socket-set-block) vs [socket_set_blocking()](https://www.php.net/manual/en/function.socket-set-blocking) , i just used t... | 8 |
lolphp | barubary | cvpj25 | <|soss|><|sot|>Problems with the official operator precedence table<|eot|><|sost|>PHP has operators. These operators have a priority called [operator precedence](https://www.php.net/manual/en/language.operators.precedence.php), as explained in the official documentation. All of this is pretty standard.
However, the ac... | 50 |
lolphp | C0c04l4 | ey67hjs | <|soss|><|sot|>Problems with the official operator precedence table<|eot|><|sost|>PHP has operators. These operators have a priority called [operator precedence](https://www.php.net/manual/en/language.operators.precedence.php), as explained in the official documentation. All of this is pretty standard.
However, the ac... | 23 |
lolphp | C0c04l4 | ey7bman | <|soss|><|sot|>Problems with the official operator precedence table<|eot|><|sost|>PHP has operators. These operators have a priority called [operator precedence](https://www.php.net/manual/en/language.operators.precedence.php), as explained in the official documentation. All of this is pretty standard.
However, the ac... | 13 |
lolphp | the_alias_of_andrea | ey62s84 | <|soss|><|sot|>Problems with the official operator precedence table<|eot|><|sost|>PHP has operators. These operators have a priority called [operator precedence](https://www.php.net/manual/en/language.operators.precedence.php), as explained in the official documentation. All of this is pretty standard.
However, the ac... | 11 |
lolphp | mikeputerbaugh | ey8arpx | <|soss|><|sot|>Problems with the official operator precedence table<|eot|><|sost|>PHP has operators. These operators have a priority called [operator precedence](https://www.php.net/manual/en/language.operators.precedence.php), as explained in the official documentation. All of this is pretty standard.
However, the ac... | 9 |
lolphp | barubary | ey8dnyj | <|soss|><|sot|>Problems with the official operator precedence table<|eot|><|sost|>PHP has operators. These operators have a priority called [operator precedence](https://www.php.net/manual/en/language.operators.precedence.php), as explained in the official documentation. All of this is pretty standard.
However, the ac... | 9 |
lolphp | barubary | ey866qp | <|soss|><|sot|>Problems with the official operator precedence table<|eot|><|sost|>PHP has operators. These operators have a priority called [operator precedence](https://www.php.net/manual/en/language.operators.precedence.php), as explained in the official documentation. All of this is pretty standard.
However, the ac... | 7 |
lolphp | Takeoded | 69mfd0 | <|sols|><|sot|>be careful where you put implementing classes<|eot|><|sol|>https://3v4l.org/LudAO<|eol|><|eols|><|endoftext|> | 48 |
lolphp | nikic | dh7vnot | <|sols|><|sot|>be careful where you put implementing classes<|eot|><|sol|>https://3v4l.org/LudAO<|eol|><|soopr|>if anyone can explain why this limitation exists for implementing classes and not for other classes, i'm all ears<|eoopr|><|sor|>The tl;dr is that right now class hoisting occurs as a consequence of early bin... | 18 |
lolphp | beerdude26 | dh7u6d8 | <|sols|><|sot|>be careful where you put implementing classes<|eot|><|sol|>https://3v4l.org/LudAO<|eol|><|soopr|>if anyone can explain why this limitation exists for implementing classes and not for other classes, i'm all ears<|eoopr|><|sor|>Countable presumably has return types and input types on its methods and class ... | 12 |
lolphp | SnowdogU77 | dh7p5ur | <|sols|><|sot|>be careful where you put implementing classes<|eot|><|sol|>https://3v4l.org/LudAO<|eol|><|soopr|>if anyone can explain why this limitation exists for implementing classes and not for other classes, i'm all ears<|eoopr|><|sor|>Countable presumably has return types and input types on its methods and class ... | 9 |
lolphp | Takeoded | dh7oq3o | <|sols|><|sot|>be careful where you put implementing classes<|eot|><|sol|>https://3v4l.org/LudAO<|eol|><|soopr|>if anyone can explain why this limitation exists for implementing classes and not for other classes, i'm all ears<|eoopr|><|eols|><|endoftext|> | 8 |
lolphp | squiggleslash | dh817qp | <|sols|><|sot|>be careful where you put implementing classes<|eot|><|sol|>https://3v4l.org/LudAO<|eol|><|sor|>I'm not seeing this, as written, as a LOL. You're using a class before defining it, by rights that should be an error.
It's arguable that the "new C1()" line should *also* fail - having an unknown class defaul... | 8 |
lolphp | senj | dh7r13f | <|sols|><|sot|>be careful where you put implementing classes<|eot|><|sol|>https://3v4l.org/LudAO<|eol|><|soopr|>if anyone can explain why this limitation exists for implementing classes and not for other classes, i'm all ears<|eoopr|><|sor|>Countable presumably has return types and input types on its methods and class ... | 8 |
lolphp | Sarcastinator | dh8m5p5 | <|sols|><|sot|>be careful where you put implementing classes<|eot|><|sol|>https://3v4l.org/LudAO<|eol|><|sor|>I'm not seeing this, as written, as a LOL. You're using a class before defining it, by rights that should be an error.
It's arguable that the "new C1()" line should *also* fail - having an unknown class defaul... | 6 |
lolphp | nightofgrim | 5rctij | <|soss|><|sot|>0 is in array of cats and dogs<|eot|><|sost|>PHP 7.0.1
<?php
$array = ['CATS','DOGS'];
if(in_array(0, $array)===true){
echo 'found zero!';
}
?>
Result: 'found zero!'
Run it yourself: http://sandbox.onlinephpfunctions.com/code/2043564ef944a98b8ecd9c95b6ecf1b1e894... | 49 |
lolphp | yawkat | dd6jwt7 | <|soss|><|sot|>0 is in array of cats and dogs<|eot|><|sost|>PHP 7.0.1
<?php
$array = ['CATS','DOGS'];
if(in_array(0, $array)===true){
echo 'found zero!';
}
?>
Result: 'found zero!'
Run it yourself: http://sandbox.onlinephpfunctions.com/code/2043564ef944a98b8ecd9c95b6ecf1b1e894... | 53 |
lolphp | vierkantor | dd6kttn | <|soss|><|sot|>0 is in array of cats and dogs<|eot|><|sost|>PHP 7.0.1
<?php
$array = ['CATS','DOGS'];
if(in_array(0, $array)===true){
echo 'found zero!';
}
?>
Result: 'found zero!'
Run it yourself: http://sandbox.onlinephpfunctions.com/code/2043564ef944a98b8ecd9c95b6ecf1b1e894... | 36 |
lolphp | squiggleslash | dd6zt3h | <|soss|><|sot|>0 is in array of cats and dogs<|eot|><|sost|>PHP 7.0.1
<?php
$array = ['CATS','DOGS'];
if(in_array(0, $array)===true){
echo 'found zero!';
}
?>
Result: 'found zero!'
Run it yourself: http://sandbox.onlinephpfunctions.com/code/2043564ef944a98b8ecd9c95b6ecf1b1e894... | 24 |
lolphp | arnoutboks | dd6s9zu | <|soss|><|sot|>0 is in array of cats and dogs<|eot|><|sost|>PHP 7.0.1
<?php
$array = ['CATS','DOGS'];
if(in_array(0, $array)===true){
echo 'found zero!';
}
?>
Result: 'found zero!'
Run it yourself: http://sandbox.onlinephpfunctions.com/code/2043564ef944a98b8ecd9c95b6ecf1b1e894... | 17 |
lolphp | garagedragon | dddopwl | <|soss|><|sot|>0 is in array of cats and dogs<|eot|><|sost|>PHP 7.0.1
<?php
$array = ['CATS','DOGS'];
if(in_array(0, $array)===true){
echo 'found zero!';
}
?>
Result: 'found zero!'
Run it yourself: http://sandbox.onlinephpfunctions.com/code/2043564ef944a98b8ecd9c95b6ecf1b1e894... | 10 |
lolphp | offroadspike | ddhsxtb | <|soss|><|sot|>0 is in array of cats and dogs<|eot|><|sost|>PHP 7.0.1
<?php
$array = ['CATS','DOGS'];
if(in_array(0, $array)===true){
echo 'found zero!';
}
?>
Result: 'found zero!'
Run it yourself: http://sandbox.onlinephpfunctions.com/code/2043564ef944a98b8ecd9c95b6ecf1b1e894... | 9 |
lolphp | bwoebi | dd74a7e | <|soss|><|sot|>0 is in array of cats and dogs<|eot|><|sost|>PHP 7.0.1
<?php
$array = ['CATS','DOGS'];
if(in_array(0, $array)===true){
echo 'found zero!';
}
?>
Result: 'found zero!'
Run it yourself: http://sandbox.onlinephpfunctions.com/code/2043564ef944a98b8ecd9c95b6ecf1b1e894... | 9 |
lolphp | TQpl0nk | dd70n71 | <|soss|><|sot|>0 is in array of cats and dogs<|eot|><|sost|>PHP 7.0.1
<?php
$array = ['CATS','DOGS'];
if(in_array(0, $array)===true){
echo 'found zero!';
}
?>
Result: 'found zero!'
Run it yourself: http://sandbox.onlinephpfunctions.com/code/2043564ef944a98b8ecd9c95b6ecf1b1e894... | 7 |
lolphp | NXTangl | ddbpquw | <|soss|><|sot|>0 is in array of cats and dogs<|eot|><|sost|>PHP 7.0.1
<?php
$array = ['CATS','DOGS'];
if(in_array(0, $array)===true){
echo 'found zero!';
}
?>
Result: 'found zero!'
Run it yourself: http://sandbox.onlinephpfunctions.com/code/2043564ef944a98b8ecd9c95b6ecf1b1e894... | 5 |
lolphp | fdelta1 | 5pk2rl | <|sols|><|sot|>strtotime() accepts "DD Month YYYY" and "Month DD, YYYY" as valid formats, but fails when given "DD Month, YYYY"<|eot|><|sol|>https://en.wiktionary.org/wiki/Wiktionary:Grease_pit#Template:quote-journal<|eol|><|eols|><|endoftext|> | 49 |
lolphp | fdelta1 | dcrxlqv | <|sols|><|sot|>strtotime() accepts "DD Month YYYY" and "Month DD, YYYY" as valid formats, but fails when given "DD Month, YYYY"<|eot|><|sol|>https://en.wiktionary.org/wiki/Wiktionary:Grease_pit#Template:quote-journal<|eol|><|sor|>Say it supported both `DD MM, YYYY` and `MM DD, YYYY`. What date would `01 02, 2016` be? T... | 44 |
lolphp | mort96 | dcruggz | <|sols|><|sot|>strtotime() accepts "DD Month YYYY" and "Month DD, YYYY" as valid formats, but fails when given "DD Month, YYYY"<|eot|><|sol|>https://en.wiktionary.org/wiki/Wiktionary:Grease_pit#Template:quote-journal<|eol|><|sor|>Say it supported both `DD MM, YYYY` and `MM DD, YYYY`. What date would `01 02, 2016` be? T... | 38 |
lolphp | n3xg3n | dcsdk8m | <|sols|><|sot|>strtotime() accepts "DD Month YYYY" and "Month DD, YYYY" as valid formats, but fails when given "DD Month, YYYY"<|eot|><|sol|>https://en.wiktionary.org/wiki/Wiktionary:Grease_pit#Template:quote-journal<|eol|><|sor|>Say it supported both `DD MM, YYYY` and `MM DD, YYYY`. What date would `01 02, 2016` be? T... | 23 |
lolphp | fdelta1 | dct9m8c | <|sols|><|sot|>strtotime() accepts "DD Month YYYY" and "Month DD, YYYY" as valid formats, but fails when given "DD Month, YYYY"<|eot|><|sol|>https://en.wiktionary.org/wiki/Wiktionary:Grease_pit#Template:quote-journal<|eol|><|sor|>To be fair, nobody writes dates as *23 January, 2016*. The comma does not belong there.<|e... | 9 |
lolphp | mort96 | dcsdp87 | <|sols|><|sot|>strtotime() accepts "DD Month YYYY" and "Month DD, YYYY" as valid formats, but fails when given "DD Month, YYYY"<|eot|><|sol|>https://en.wiktionary.org/wiki/Wiktionary:Grease_pit#Template:quote-journal<|eol|><|sor|>Say it supported both `DD MM, YYYY` and `MM DD, YYYY`. What date would `01 02, 2016` be? T... | 9 |
lolphp | Porges | dcsikrr | <|sols|><|sot|>strtotime() accepts "DD Month YYYY" and "Month DD, YYYY" as valid formats, but fails when given "DD Month, YYYY"<|eot|><|sol|>https://en.wiktionary.org/wiki/Wiktionary:Grease_pit#Template:quote-journal<|eol|><|sor|>Excel has the opposite: it parses `DD Month, YYYY` but not `Month DD, YYYY`.<|eor|><|eols|... | 6 |
lolphp | ZiggyTheHamster | dct65jr | <|sols|><|sot|>strtotime() accepts "DD Month YYYY" and "Month DD, YYYY" as valid formats, but fails when given "DD Month, YYYY"<|eot|><|sol|>https://en.wiktionary.org/wiki/Wiktionary:Grease_pit#Template:quote-journal<|eol|><|sor|>To be fair, nobody writes dates as *23 January, 2016*. The comma does not belong there.<|e... | 6 |
lolphp | Yaamboo | dcsdri0 | <|sols|><|sot|>strtotime() accepts "DD Month YYYY" and "Month DD, YYYY" as valid formats, but fails when given "DD Month, YYYY"<|eot|><|sol|>https://en.wiktionary.org/wiki/Wiktionary:Grease_pit#Template:quote-journal<|eol|><|sor|>Say it supported both `DD MM, YYYY` and `MM DD, YYYY`. What date would `01 02, 2016` be? T... | 6 |
lolphp | the_alias_of_andrea | 42u1hp | <|sols|><|sot|>consistency is great<|eot|><|sol|>https://3v4l.org/2qdPp<|eol|><|eols|><|endoftext|> | 48 |
lolphp | the_alias_of_andrea | czd38cv | <|sols|><|sot|>consistency is great<|eot|><|sol|>https://3v4l.org/2qdPp<|eol|><|soopr|>What's going on here? Well, string-to-integer conversion handles overflow differently from float-to-integer conversion. Because PHP.
It might appear things were fixed pre-5.4 and in HHVM, but that's not actually the case, it's just ... | 30 |
lolphp | djsumdog | 3v56xi | <|sols|><|sot|>PHP 7 has just been released. So what's fixed and what's still hopelessly broken?<|eot|><|sol|>https://github.com/php/php-src/releases/tag/php-7.0.0<|eol|><|eols|><|endoftext|> | 47 |
lolphp | iheartrms | cxkg9ew | <|sols|><|sot|>PHP 7 has just been released. So what's fixed and what's still hopelessly broken?<|eot|><|sol|>https://github.com/php/php-src/releases/tag/php-7.0.0<|eol|><|sor|>Per /u/antpocus over on /r/programming:
> Ooh, only 137 compiler warnings and > 102 failed tests! That's a huge
> improvement from 5.6's 638
... | 33 |
lolphp | gearvOsh | cxkqnmq | <|sols|><|sot|>PHP 7 has just been released. So what's fixed and what's still hopelessly broken?<|eot|><|sol|>https://github.com/php/php-src/releases/tag/php-7.0.0<|eol|><|sor|>> what's still hopelessly broken?
PHP still not a deprecated language?<|eor|><|sor|>PHP 7 is far far far less shittier than PHP 5.2/3 was.<|eo... | 32 |
lolphp | postmodest | cxkm0h0 | <|sols|><|sot|>PHP 7 has just been released. So what's fixed and what's still hopelessly broken?<|eot|><|sol|>https://github.com/php/php-src/releases/tag/php-7.0.0<|eol|><|sor|>Per /u/antpocus over on /r/programming:
> Ooh, only 137 compiler warnings and > 102 failed tests! That's a huge
> improvement from 5.6's 638
... | 23 |
lolphp | OneWingedShark | cxkgfo1 | <|sols|><|sot|>PHP 7 has just been released. So what's fixed and what's still hopelessly broken?<|eot|><|sol|>https://github.com/php/php-src/releases/tag/php-7.0.0<|eol|><|sor|>>So what's fixed and what's still hopelessly broken?
Well, despite how it's obviously needed, the type-annotation system is -- you simply cann... | 22 |
lolphp | gearvOsh | cxko7wq | <|sols|><|sot|>PHP 7 has just been released. So what's fixed and what's still hopelessly broken?<|eot|><|sol|>https://github.com/php/php-src/releases/tag/php-7.0.0<|eol|><|sor|>> what's still hopelessly broken?
PHP still not a deprecated language?<|eor|><|sor|>PHP 7 is far far far less shittier than PHP 5.2/3 was.<|eo... | 19 |
lolphp | Artemis2 | cxkw0bi | <|sols|><|sot|>PHP 7 has just been released. So what's fixed and what's still hopelessly broken?<|eot|><|sol|>https://github.com/php/php-src/releases/tag/php-7.0.0<|eol|><|sor|>Off the top of my head, unicode? Let's just wait until they release PHP 6<|eor|><|eols|><|endoftext|> | 18 |
lolphp | vithos | cxkjler | <|sols|><|sot|>PHP 7 has just been released. So what's fixed and what's still hopelessly broken?<|eot|><|sol|>https://github.com/php/php-src/releases/tag/php-7.0.0<|eol|><|sor|>Per /u/antpocus over on /r/programming:
> Ooh, only 137 compiler warnings and > 102 failed tests! That's a huge
> improvement from 5.6's 638
... | 17 |
lolphp | AlGoreBestGore | cxkfk5u | <|sols|><|sot|>PHP 7 has just been released. So what's fixed and what's still hopelessly broken?<|eot|><|sol|>https://github.com/php/php-src/releases/tag/php-7.0.0<|eol|><|sor|>Who needs PHP 6 when you can have PHP 7?<|eor|><|eols|><|endoftext|> | 15 |
lolphp | Cuddlefluff_Grim | cxlmssc | <|sols|><|sot|>PHP 7 has just been released. So what's fixed and what's still hopelessly broken?<|eot|><|sol|>https://github.com/php/php-src/releases/tag/php-7.0.0<|eol|><|sor|>Who needs PHP 6 when you can have PHP 7?<|eor|><|sor|>[deleted]<|eor|><|sor|>Microsoft didn't cancel Windows 9 because they weren't competent e... | 12 |
lolphp | McGlockenshire | cxkzdxo | <|sols|><|sot|>PHP 7 has just been released. So what's fixed and what's still hopelessly broken?<|eot|><|sol|>https://github.com/php/php-src/releases/tag/php-7.0.0<|eol|><|sor|>> what's still hopelessly broken?
PHP still not a deprecated language?<|eor|><|sor|>PHP 7 is far far far less shittier than PHP 5.2/3 was.<|eo... | 12 |
lolphp | Creshal | cxmthua | <|sols|><|sot|>PHP 7 has just been released. So what's fixed and what's still hopelessly broken?<|eot|><|sol|>https://github.com/php/php-src/releases/tag/php-7.0.0<|eol|><|sor|><|eor|><|soopr|>Um...what other languages throw exceptions for that? Java/Scala give you +/- Infinity. If anything, they're now more like other... | 11 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.