### Re: Bits & pieces

by jdalbec (Deacon)
 on Jul 16, 2005 at 03:18 UTC Need Help??

```\$_ = [
[
...
]
];
(%_) = %{ \${ \${ \$_; }[0]; }[1]; };
```
```undef \$_;
%_ = (
...
65 => '011100001001010100000001'
#                  012345678901234567890123
);
```
```\$s = eval {
do {
...

}
};
```
```\$o = pack( 'b*', \$_{9} );
foreach \$_ ( 0 .. unpack( '%b*', \$o ) - 2 ) {
# 16 bit checksum = 25, - 2 = 23
```
```    \$c = \$_ - ( ( \$_ - \$_ % 4 ) / 4 + ( \$_ % 4 ? 1 : 0 ) );
# print \$c;
...
#    1010  0010  0000  1111  0001  0100  0000  0100  1000  1000  0101
+ 0100
# J  u  r  t        n  o  u  h  e  r     P  d  r  l  a  h  a  b  j  e
+ r
#       *        *        *                 *        *        *  *
```
```    \$i += \$i % 2 ? -1 : 1 # \$i ^= 1
if ( \$_ + 1 ) % 12 and not(( \$_ + 1 ) % 3)
...
# print \$i % 16;
# 10 5 3 4 0 1 14 15 4 8 5 2 0 0 5 2 12 0 8 1 3 11 5 2
# J  u s t   a n  o  t h e r   P e r l    h a c k  e r
```
```    \$T =
vec( pack( 'C', \$i ), 0, 4 ) + vec( pack( 'b*', \$_{65} ), \$_, 1
+) * 16 +
...
# 0  1  1  1  0  0  0  0  1  0  0  1  0  1  0  1  0  0  0  0  0  0  0
+ 1
# J  u  s  t     a  n  o  t  h  e  r     P  e  r  l     h  a  c  k  e
+ r
# *  1  2  3  4  5  6  7  8  9  10 11 12 *  1  2  3  4  5  6  7  8  9
+ 10
```
```    print pack( 'c', ( \$T += \$T == 32 ? 0 : 64 ) -= \$_ % 13 == 0 ? 32
+: 0 );
```
```#    &\$s; # independent of rest of loop, unrolled
}
...
# 00   14294967295  2105  38   44294967263  573   68   74294967263  87
+7
# 94   104294967291 1153  120  134294967295 14116 1520 164294967263 17
+112
# 1813 194294967282 20125 2116 224294967295 23116
```
```print pack( 'c', &\$s(1) ^ unpack( 'c', pack( 'b*', \$_{72} ) ) );
```

Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://475403]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others perusing the Monastery: (4)
As of 2024-05-27 22:24 GMT
Sections?
Information?
Find Nodes?
Leftovers?
Voting Booth?

No recent polls found