FUDforum
Fast Uncompromising Discussions. FUDforum will get your users talking.

Home » Imported messages » comp.lang.php » switch with range of comparisons
Show: Today's Messages :: Polls :: Message Navigator
Return to the default flat view Create a new topic Submit Reply
Re: switch with range of comparisons [message #184642 is a reply to message #184639] Tue, 14 January 2014 01:36 Go to previous messageGo to previous message
Denis McMahon is currently offline  Denis McMahon
Messages: 634
Registered: September 2010
Karma:
Senior Member
On Tue, 14 Jan 2014 00:30:00 +0000, Beauregard T. Shagnasty wrote:

> richard the sto0pid wrote:
>
>> switch ($value){
>>
>> case "A">="Z";
>>
>> }
>>
>> Would this be allowed?
>
> How will "A" ever be equal-to or greater-than "Z"?
>
>> What I want to do is to have one case for all 26 letters of the
>> alphabet without having to use ||.
>
> Why would you want to use switch for only one condition?
>
> Go to your local big box store and purchase a carton of Logic.

I think what richard meant to ask was:

will

case >=A && <=Z :

work

But he couldn't even figure that out, and he obviously didn't run my
example php program that attempted to show him that he was working from a
flawed understanding.

Oh well, roll on the fucked up code.

As for whether it will work or not, well I'm buggered if I can be arsed
to help richard any more. He can find out for himself.

And now for a special message to richard:

richard, your comprehension of how switch statements work is currently so
fucked up that you are presently incapable of coding one that does what
you want, even if it appears to do so under test conditions with the
limited test data that you feed it. I strongly suggest you take a
sabbatical from your project to learn basic php programming syntax before
doing any more work on your website. 50 years might do it, although with
your current record, it might be best to set aside at least 300.

--
Denis McMahon, denismfmcmahon(at)gmail(dot)com
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: When a random file is not found then what?
Next Topic: [CM] Falkvinge: MtGox had custom SSHD written in PHP
Goto Forum:
  

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ]

Current Time: Mon Sep 30 04:08:54 GMT 2024

Total time taken to generate the page: 0.05839 seconds