<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    <meta content="text/html; charset=ISO-8859-1"
      http-equiv="Content-Type">
  </head>
  <body text="#000000" bgcolor="#ffffff">
    This reminds of some C code a mate showed me back in the late '80s
    from one of the UNIX flavours at the time. One was some nasty code
    in crypt.c, the worst was a 150 character single line (with no
    spaces) from somewhere inside the task scheduler.<br>
    <br>
    There was serious use of nested:<br>
    <br>
    &nbsp;&nbsp;&nbsp; a ? b : c<br>
    <br>
    conditions, a good number of using pointer to function array calls.
    And some other hideous things with for loops and inc/decs. <br>
    <br>
    OK I understand that in the scheduler you want good performance and
    compact code to get the most out of it, but some things were never
    meant to be written.<br>
    <br>
    Kev,<br>
    <br>
    <br>
    On 30/11/10 06:34, Thomas Edward Groves wrote:
    <blockquote cite="mid:004201cb9058$b3304d00$374b08c3@x1u9e2"
      type="cite">
      <meta content="text/html; charset=ISO-8859-1"
        http-equiv="Content-Type">
      <meta content="MSHTML 5.00.2614.3500" name="GENERATOR">
      <style></style>
      <div><font size="2" face="Arial">Actually I've never seen a
          language that doesn't allow the most horrible spaghetti.</font></div>
      <div><font size="2" face="Arial">It's just that some languages
          make it easy.</font></div>
      <div><font size="2" face="Arial">On the other hand the languages
          which make it hard to write crap also make it</font></div>
      <div><font size="2" face="Arial">hard to write stuff that the
          designers of that language hadn't thought of.</font></div>
      <div><font size="2" face="Arial">C was designed to let the
          programmer have all the rope he wanted,</font></div>
      <div><font size="2" face="Arial">that's why we so often hang
          ourselves when using it.</font></div>
      <div><font size="2" face="Arial">It's also why some of us so often
          return to it too.</font></div>
      <div>&nbsp;</div>
      <div><font size="2" face="Arial">And as for code beautifiers:
          they're the most valuable tool that never gets mentioned</font></div>
      <div><font size="2" face="Arial">in books on programming that I
          know of.</font></div>
      <div>&nbsp;</div>
      <div><font size="2" face="Arial">Odd that.</font></div>
      <div>&nbsp;</div>
      <div><font size="2" face="Arial">Tom</font></div>
      <blockquote style="border-left: 2px solid rgb(0, 0, 0);
        margin-left: 5px; margin-right: 0px; padding-left: 5px;
        padding-right: 0px;">
        <div style="font: 10pt arial;">----- Original Message ----- </div>
        <div style="background: none repeat scroll 0% 0% rgb(228, 228,
          228); font: 10pt arial;"><b>From:</b> <a
            moz-do-not-send="true" href="mailto:pchilds@bcs.org"
            title="pchilds@bcs.org">Peter Childs</a> </div>
        <div style="font: 10pt arial;"><b>To:</b> <a
            moz-do-not-send="true" href="mailto:kent@mailman.lug.org.uk"
            title="kent@mailman.lug.org.uk">Kent Linux User Group -
            General Topics</a> </div>
        <div style="font: 10pt arial;"><b>Sent:</b> Monday, November 29,
          2010 2:46 PM</div>
        <div style="font: 10pt arial;"><b>Subject:</b> Re:
          [Klug-general] Obscure C at saturday's meeting</div>
        <div><br>
        </div>
        <br>
        <br>
        <div class="gmail_quote">On 29 November 2010 14:35, David
          Halliday <span dir="ltr">&lt;<a moz-do-not-send="true"
              href="mailto:david.halliday@gmail.com">david.halliday@gmail.com</a>&gt;</span>
          wrote:<br>
          <blockquote class="gmail_quote" style="border-left: 1px solid
            rgb(204, 204, 204); margin: 0px 0px 0px 0.8ex; padding-left:
            1ex;">There is a reason why C as a language does
            lean&nbsp;beautifully&nbsp;to code obfuscation.&nbsp;We all know that C was
            just a joke that has got out of hand,&nbsp;alongside&nbsp;the base of
            all *nix&nbsp;environments:&nbsp;<a moz-do-not-send="true"
              href="http://www.asandler.com/jokes/computer/c.shtml"
              target="_blank">http://www.asandler.com/jokes/computer/c.shtml</a>
            <div><br>
            </div>
            <div>From The Article:</div>
            <div>We stopped when we got a clean compile on the following
              syntax:<br>
              <font face="'courier new', monospace">for(;P("\n"),R-;P("|"))for(e=C;e-;P("_"+(*u++/8)%2))P("|"+(*u/4)%2);</font><br>
              <br>
              To think that modern programmers would try to use a
              language that allowed such a statement was beyond our
              comprehension!</div>
            <div><br>
            </div>
          </blockquote>
          <div><br>
          </div>
          <div>Perl has a reputation for this too.....</div>
          <div><br>
          </div>
          <div>Peter.</div>
          <div>&nbsp;</div>
          <blockquote class="gmail_quote" style="border-left: 1px solid
            rgb(204, 204, 204); margin: 0px 0px 0px 0.8ex; padding-left:
            1ex;">
            <div><br>
            </div>
            <div><br>
            </div>
            <div>
              <div class="gmail_quote">
                <div class="im">On 29 November 2010 12:53, Dan Attwood <span
                    dir="ltr">&lt;<a moz-do-not-send="true"
                      href="mailto:danattwood@gmail.com" target="_blank">danattwood@gmail.com</a>&gt;</span>
                  wrote:<br>
                </div>
                <blockquote class="gmail_quote" style="border-left: 1px
                  solid rgb(204, 204, 204); margin: 0px 0px 0px 0.8ex;
                  padding-left: 1ex;">
                  <div class="im">
                    <div class="gmail_quote">
                      <div><br>
                        <blockquote class="gmail_quote"
                          style="border-left: 1px solid rgb(204, 204,
                          204); margin: 0px 0px 0px 0.8ex; padding-left:
                          1ex;"><br>
                          And for exactly this reason there has been a
                          policy in places I have worked of running any
                          C code through the C beautifier automatically
                          as part of the version control check-in
                          process. &nbsp;This has the advantage that coders
                          arbitrarily rearranging the code in their
                          preferred style whilst editing does not look
                          like a change, and that all code retrieved is
                          always in the house style, which makes for
                          easier debugging.<br>
                          <br>
                        </blockquote>
                      </div>
                      <div>someone at barcamp was talking about do just
                        this. Although they went one step further where
                        if it fell outside of some rules then they would
                        stop it from compiling and spit it back at the
                        developer&nbsp;</div>
                    </div>
                    <br>
                  </div>
                  <div class="im">_______________________________________________<br>
                    Kent mailing list<br>
                    <a moz-do-not-send="true"
                      href="mailto:Kent@mailman.lug.org.uk"
                      target="_blank">Kent@mailman.lug.org.uk</a><br>
                    <a moz-do-not-send="true"
                      href="https://mailman.lug.org.uk/mailman/listinfo/kent"
                      target="_blank">https://mailman.lug.org.uk/mailman/listinfo/kent</a><br>
                  </div>
                </blockquote>
              </div>
              <br>
            </div>
            <br>
            _______________________________________________<br>
            Kent mailing list<br>
            <a moz-do-not-send="true"
              href="mailto:Kent@mailman.lug.org.uk">Kent@mailman.lug.org.uk</a><br>
            <a moz-do-not-send="true"
              href="https://mailman.lug.org.uk/mailman/listinfo/kent"
              target="_blank">https://mailman.lug.org.uk/mailman/listinfo/kent</a><br>
          </blockquote>
        </div>
        <br>
        <p> </p>
        <hr> _______________________________________________<br>
        Kent mailing list<br>
        <a class="moz-txt-link-abbreviated" href="mailto:Kent@mailman.lug.org.uk">Kent@mailman.lug.org.uk</a><br>
        <a class="moz-txt-link-freetext" href="https://mailman.lug.org.uk/mailman/listinfo/kent">https://mailman.lug.org.uk/mailman/listinfo/kent</a></blockquote>
      <pre wrap="">
<fieldset class="mimeAttachmentHeader"></fieldset>
_______________________________________________
Kent mailing list
<a class="moz-txt-link-abbreviated" href="mailto:Kent@mailman.lug.org.uk">Kent@mailman.lug.org.uk</a>
<a class="moz-txt-link-freetext" href="https://mailman.lug.org.uk/mailman/listinfo/kent">https://mailman.lug.org.uk/mailman/listinfo/kent</a></pre>
    </blockquote>
  </body>
</html>