Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. The Lounge
  3. The Greatest Answer in the History of StackOverflow?

The Greatest Answer in the History of StackOverflow?

Scheduled Pinned Locked Moved The Lounge
regexquestioncomtutorial
27 Posts 19 Posters 1 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • A Alexander DiMauro

    There is probably a good chance this was posted here before, since it's from 5 years ago, but, I'm a little slow and just found this today from a link on Twitter. Read the accepted answer for this question. Read the whole thing, it's brilliant! http://stackoverflow.com/questions/1732348/regex-match-open-tags-except-xhtml-self-contained-tags[^] Any other great answers out there that people know of?

    I have always wished for my computer to be as easy to use as my telephone; my wish has come true because I can no longer figure out how to use my telephone - Bjarne Stroustrup My code has no bugs, it runs exactly as it was written.

    S Offline
    S Offline
    Slacker007
    wrote on last edited by
    #3

    If Jon Skeet can't do it, then it can't be done.

    V 1 Reply Last reply
    0
    • A Alexander DiMauro

      There is probably a good chance this was posted here before, since it's from 5 years ago, but, I'm a little slow and just found this today from a link on Twitter. Read the accepted answer for this question. Read the whole thing, it's brilliant! http://stackoverflow.com/questions/1732348/regex-match-open-tags-except-xhtml-self-contained-tags[^] Any other great answers out there that people know of?

      I have always wished for my computer to be as easy to use as my telephone; my wish has come true because I can no longer figure out how to use my telephone - Bjarne Stroustrup My code has no bugs, it runs exactly as it was written.

      B Offline
      B Offline
      Brisingr Aerowing
      wrote on last edited by
      #4

      This one[^] (First code block)

      What do you get when you cross a joke with a rhetorical question? --- The metaphorical solid rear-end expulsions have impacted the metaphorical motorized bladed rotating air movement mechanism. --- Do questions with multiple question marks annoy you???

      R A 2 Replies Last reply
      0
      • N Nish Nishant

        Don't know if that's the greatest answer I've seen on SO, but it's posted by someone who's got a high chance of being a complete jerk in real life.

        Regards, Nish


        Blog: voidnish.wordpress.com

        P Offline
        P Offline
        Pete OHanlon
        wrote on last edited by
        #5

        Surely it's not one of my posts on SO?

        N 1 Reply Last reply
        0
        • A Alexander DiMauro

          There is probably a good chance this was posted here before, since it's from 5 years ago, but, I'm a little slow and just found this today from a link on Twitter. Read the accepted answer for this question. Read the whole thing, it's brilliant! http://stackoverflow.com/questions/1732348/regex-match-open-tags-except-xhtml-self-contained-tags[^] Any other great answers out there that people know of?

          I have always wished for my computer to be as easy to use as my telephone; my wish has come true because I can no longer figure out how to use my telephone - Bjarne Stroustrup My code has no bugs, it runs exactly as it was written.

          L Offline
          L Offline
          Lost User
          wrote on last edited by
          #6

          I like the answer one below....

          Quote:

          While it is true that asking regexes to parse arbitrary HTML is like asking Paris Hilton to write an operating system, it's sometimes appropriate to parse a limited, known set of HTML.

          N L 2 Replies Last reply
          0
          • L Lost User

            I like the answer one below....

            Quote:

            While it is true that asking regexes to parse arbitrary HTML is like asking Paris Hilton to write an operating system, it's sometimes appropriate to parse a limited, known set of HTML.

            N Offline
            N Offline
            Nish Nishant
            wrote on last edited by
            #7

            Why is that funny? Paris's work on the Ubuntu kernel is legendary! :confused:

            Regards, Nish


            Blog: voidnish.wordpress.com

            K 1 Reply Last reply
            0
            • P Pete OHanlon

              Surely it's not one of my posts on SO?

              N Offline
              N Offline
              Nish Nishant
              wrote on last edited by
              #8

              Hah :-D

              Regards, Nish


              Blog: voidnish.wordpress.com

              1 Reply Last reply
              0
              • A Alexander DiMauro

                There is probably a good chance this was posted here before, since it's from 5 years ago, but, I'm a little slow and just found this today from a link on Twitter. Read the accepted answer for this question. Read the whole thing, it's brilliant! http://stackoverflow.com/questions/1732348/regex-match-open-tags-except-xhtml-self-contained-tags[^] Any other great answers out there that people know of?

                I have always wished for my computer to be as easy to use as my telephone; my wish has come true because I can no longer figure out how to use my telephone - Bjarne Stroustrup My code has no bugs, it runs exactly as it was written.

                A Offline
                A Offline
                Afzaal Ahmad Zeeshan
                wrote on last edited by
                #9

                If you want to read some great answers, please read the answers from Jon Skeet[^]'s profile. I didn't get much chance to get answers to my (stupid) questions from Mr. Skeet, but as much as he has answered, were some of the best answers in my questioning history. His method of answering a question is just like asking a question to your own friend.

                The shit I complain about It's like there ain't a cloud in the sky and it's raining out - Eminem ~! Firewall !~

                1 Reply Last reply
                0
                • B Brisingr Aerowing

                  This one[^] (First code block)

                  What do you get when you cross a joke with a rhetorical question? --- The metaphorical solid rear-end expulsions have impacted the metaphorical motorized bladed rotating air movement mechanism. --- Do questions with multiple question marks annoy you???

                  R Offline
                  R Offline
                  realJSOP
                  wrote on last edited by
                  #10

                  //
                  // Dear maintainer:
                  //
                  // Once you are done trying to 'optimize' this routine,
                  // and have realized what a terrible mistake that was,
                  // please increment the following counter as a warning
                  // to the next guy:
                  //
                  // total_hours_wasted_here = 42
                  //

                  F*ckin outstanding. :)

                  ".45 ACP - because shooting twice is just silly" - JSOP, 2010
                  -----
                  You can never have too much ammo - unless you're swimming, or on fire. - JSOP, 2010
                  -----
                  When you pry the gun from my cold dead hands, be careful - the barrel will be very hot. - JSOP, 2013

                  B K 2 Replies Last reply
                  0
                  • S Slacker007

                    If Jon Skeet can't do it, then it can't be done.

                    V Offline
                    V Offline
                    V 0
                    wrote on last edited by
                    #11

                    I dunno, maybe Chuck Norris could have a crack at it ;P

                    V.
                    (MQOTD rules and previous solutions)

                    Q F 2 Replies Last reply
                    0
                    • A Alexander DiMauro

                      There is probably a good chance this was posted here before, since it's from 5 years ago, but, I'm a little slow and just found this today from a link on Twitter. Read the accepted answer for this question. Read the whole thing, it's brilliant! http://stackoverflow.com/questions/1732348/regex-match-open-tags-except-xhtml-self-contained-tags[^] Any other great answers out there that people know of?

                      I have always wished for my computer to be as easy to use as my telephone; my wish has come true because I can no longer figure out how to use my telephone - Bjarne Stroustrup My code has no bugs, it runs exactly as it was written.

                      N Offline
                      N Offline
                      Nemanja Trifunovic
                      wrote on last edited by
                      #12

                      My favorite one is Shog's answer to the question about the difference between JavaScript and Java[^]:

                      Quote:

                      One is essentially a toy, designed for writing small pieces of code, and traditionally used and abused by inexperienced programmers. The other is a scripting language for web browsers.

                      utf8-cpp

                      1 Reply Last reply
                      0
                      • A Alexander DiMauro

                        There is probably a good chance this was posted here before, since it's from 5 years ago, but, I'm a little slow and just found this today from a link on Twitter. Read the accepted answer for this question. Read the whole thing, it's brilliant! http://stackoverflow.com/questions/1732348/regex-match-open-tags-except-xhtml-self-contained-tags[^] Any other great answers out there that people know of?

                        I have always wished for my computer to be as easy to use as my telephone; my wish has come true because I can no longer figure out how to use my telephone - Bjarne Stroustrup My code has no bugs, it runs exactly as it was written.

                        L Offline
                        L Offline
                        Lost User
                        wrote on last edited by
                        #13

                        Alexander Yee's explanation of why processing a sorted array is faster[^] (well, in that case). Not because it has many upvotes or even because I learned something from it (I didn't), but because it's one of those things that no one seems to know about but are very important anyway, and that answer makes it accessible to those people.

                        J 1 Reply Last reply
                        0
                        • N Nish Nishant

                          Why is that funny? Paris's work on the Ubuntu kernel is legendary! :confused:

                          Regards, Nish


                          Blog: voidnish.wordpress.com

                          K Offline
                          K Offline
                          Kenneth Haugland
                          wrote on last edited by
                          #14

                          Picture/Video or it didn't happen ;P

                          OriginalGriffO 1 Reply Last reply
                          0
                          • A Alexander DiMauro

                            There is probably a good chance this was posted here before, since it's from 5 years ago, but, I'm a little slow and just found this today from a link on Twitter. Read the accepted answer for this question. Read the whole thing, it's brilliant! http://stackoverflow.com/questions/1732348/regex-match-open-tags-except-xhtml-self-contained-tags[^] Any other great answers out there that people know of?

                            I have always wished for my computer to be as easy to use as my telephone; my wish has come true because I can no longer figure out how to use my telephone - Bjarne Stroustrup My code has no bugs, it runs exactly as it was written.

                            L Offline
                            L Offline
                            Lost User
                            wrote on last edited by
                            #15

                            Wow, that didn't even seem like an unreasonable question. Certainly a good way to put people off ever asking a question on SO :wtf:

                            How do you know so much about swallows? Well, you have to know these things when you're a king, you know.

                            1 Reply Last reply
                            0
                            • L Lost User

                              I like the answer one below....

                              Quote:

                              While it is true that asking regexes to parse arbitrary HTML is like asking Paris Hilton to write an operating system, it's sometimes appropriate to parse a limited, known set of HTML.

                              L Offline
                              L Offline
                              Lost User
                              wrote on last edited by
                              #16

                              Probably referring to the new Microsoft Paris Hilton Lens, written entirely in Microsoft new language PH#.

                              How do you know so much about swallows? Well, you have to know these things when you're a king, you know.

                              S 1 Reply Last reply
                              0
                              • K Kenneth Haugland

                                Picture/Video or it didn't happen ;P

                                OriginalGriffO Offline
                                OriginalGriffO Offline
                                OriginalGriff
                                wrote on last edited by
                                #17

                                No! Please, for gawd sake NO!

                                Bad command or file name. Bad, bad command! Sit! Stay! Staaaay...

                                "I have no idea what I did, but I'm taking full credit for it." - ThisOldTony
                                "Common sense is so rare these days, it should be classified as a super power" - Random T-shirt

                                1 Reply Last reply
                                0
                                • R realJSOP

                                  //
                                  // Dear maintainer:
                                  //
                                  // Once you are done trying to 'optimize' this routine,
                                  // and have realized what a terrible mistake that was,
                                  // please increment the following counter as a warning
                                  // to the next guy:
                                  //
                                  // total_hours_wasted_here = 42
                                  //

                                  F*ckin outstanding. :)

                                  ".45 ACP - because shooting twice is just silly" - JSOP, 2010
                                  -----
                                  You can never have too much ammo - unless you're swimming, or on fire. - JSOP, 2010
                                  -----
                                  When you pry the gun from my cold dead hands, be careful - the barrel will be very hot. - JSOP, 2013

                                  B Offline
                                  B Offline
                                  Brisingr Aerowing
                                  wrote on last edited by
                                  #18

                                  I know of a lot of code that could use that.

                                  What do you get when you cross a joke with a rhetorical question? --- The metaphorical solid rear-end expulsions have impacted the metaphorical motorized bladed rotating air movement mechanism. --- Do questions with multiple question marks annoy you???

                                  1 Reply Last reply
                                  0
                                  • B Brisingr Aerowing

                                    This one[^] (First code block)

                                    What do you get when you cross a joke with a rhetorical question? --- The metaphorical solid rear-end expulsions have impacted the metaphorical motorized bladed rotating air movement mechanism. --- Do questions with multiple question marks annoy you???

                                    A Offline
                                    A Offline
                                    Alexander DiMauro
                                    wrote on last edited by
                                    #19

                                    Rickrolled!

                                    I have always wished for my computer to be as easy to use as my telephone; my wish has come true because I can no longer figure out how to use my telephone - Bjarne Stroustrup The world is going to laugh at you anyway, might as well crack the 1st joke! My code has no bugs, it runs exactly as it was written.

                                    1 Reply Last reply
                                    0
                                    • V V 0

                                      I dunno, maybe Chuck Norris could have a crack at it ;P

                                      V.
                                      (MQOTD rules and previous solutions)

                                      Q Offline
                                      Q Offline
                                      Quirkafleeg
                                      wrote on last edited by
                                      #20

                                      This guy would probably delegate him to do it: :) Peter C.

                                      1 Reply Last reply
                                      0
                                      • L Lost User

                                        Probably referring to the new Microsoft Paris Hilton Lens, written entirely in Microsoft new language PH#.

                                        How do you know so much about swallows? Well, you have to know these things when you're a king, you know.

                                        S Offline
                                        S Offline
                                        SortaCore
                                        wrote on last edited by
                                        #21

                                        Visual PH# Studio 2015 SP3 to be released with three editions: Ultimate, Professional, and Express[ly Irritating].

                                        U 1 Reply Last reply
                                        0
                                        • V V 0

                                          I dunno, maybe Chuck Norris could have a crack at it ;P

                                          V.
                                          (MQOTD rules and previous solutions)

                                          F Offline
                                          F Offline
                                          Freak30
                                          wrote on last edited by
                                          #22

                                          It was already mentioned in the comments. "Chuck Norris doesn't parse HTML. When he shows up it parses itself."

                                          The good thing about pessimism is, that you are always either right or pleasently surprised.

                                          1 Reply Last reply
                                          0
                                          Reply
                                          • Reply as topic
                                          Log in to reply
                                          • Oldest to Newest
                                          • Newest to Oldest
                                          • Most Votes


                                          • Login

                                          • Don't have an account? Register

                                          • Login or register to search.
                                          • First post
                                            Last post
                                          0
                                          • Categories
                                          • Recent
                                          • Tags
                                          • Popular
                                          • World
                                          • Users
                                          • Groups