Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW
 
PerlMonks  

Comment on

( #3333=superdoc: print w/replies, xml ) Need Help??

Don't take things so literally.

Of course we know our 6 times tables. And the computer is already switched on.

What if your requirements change, and it's 7 4-bit values, or 10 3-bit values? In my code, you only have to change one or two initialisers. In Thelonius's code you have to rework nearly all of it. Even if the particular edits are trivial, there are far too many.

It's a variant on the Don't Repeat Yourself principle. I am surprised you didn't grasp this.

• another intruder with the mooring in the heart of the Perl


In reply to Re^5: 5x6-bit values into/out of a 32-bit word by grinder
in thread 5x6-bit values into/out of a 32-bit word by BrowserUk

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post; it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.
  • Log In?
    Username:
    Password:

    What's my password?
    Create A New User
    Chatterbox?
    [Corion]: GrandFather: All's well that ends well? ;)
    [GrandFather]: I'm fighting with a third party device our software is to support. The documentation for the device's SDK is quite a lot less than average and most of today was spent ...
    [GrandFather]: discovering that one of the sensors for the device lies about the gain range it is using!
    [GrandFather]: However, by the end of the day I had discovered its deceptions and now have it working correctly, so yes, all's well that ends well. :-D
    [Corion]: GrandFather: Ah, (hardware) APIs - I have a similar situation with Chrome and its API... It is fairly underdocumented and I guess I have to hunt...
    [Corion]: ... down supposedly working code to find out what I'm supposed to do
    [GrandFather]: I haven't any "working code" to inspect! I have to find ways to generate reference signals then check the numbers I get at the far end match.
    [GrandFather]: That's ok when the signal is a voltage, but there are three axis accelerometers, gyroscopes and magnetometers in these things! A little invention is needed at times!

    How do I use this? | Other CB clients
    Other Users?
    Others pondering the Monastery: (5)
    As of 2017-08-24 07:08 GMT
    Sections?
    Information?
    Find Nodes?
    Leftovers?
      Voting Booth?
      Who is your favorite scientist and why?



























      Results (365 votes). Check out past polls.

      Notices?