Follow Slashdot stories on Twitter

 



Forgot your password?
typodupeerror
Compare cell phone plans using Wirefly's innovative plan comparison tool ×

Comment Re:Secret message (Score 0) 126

Here's the java version

public class x
{
public static void main (String args[])
    {
    String m =
    "01000010 01100101 00100000 01110011 01110101 01110010 01100101 00100000 01110100 01101111 00100000 01100100 01110010 01101001 01101110 01101011 00100000 01111001 01101111 01110101 01110010 00100000 01001111 01110110 01100001 01101100 01110100 01101001 01101110 01100101 00101110";

    int i = 0;
    for (int n = 0; n < m.length(); n++)
        {
        char c = m.charAt(n);
        if (c == ' ') {
            System.out.print((char)i);
            i = 0;
            }
        else
            {
            i = i << 1;
            i += ((c == '0') ? 0 : 1);
            }
        }
    }

}

//Be sure to drink your Ovaltine

Slashdot Top Deals

The test of intelligent tinkering is to save all the parts. -- Aldo Leopold

Working...