Showing posts tagged as "geek"

Simple (yet effective) Wikipedia SOPA blackout workaround

Need Wiki bad? Getting withdrawal symptoms? Well there’s several ways to get around the outage (including one very simple way (at the bottom)). Are you plagued by this screen:

Well fear not! Any of the below should work for you:

  • Go to the still-operational Simple English Wikipedia. However not all articles will be available so might not be optimal for you.
  • Understand what’s happening: If you go to any page on the En wiki you’ll probably notice it load fine and then suddenly it’s gone? Well what it’s doing is overlaying a full-screen div with id=mw-sopaOverlay and setting all of the normal elements that were there just a split second ago to display:none;. So you have two options:
    1. Do something clever like disable just the right part of the javascript or…
    2. Do something very very simple: When you can see the page that you wanted has loaded, press the STOP button in your browser which will stop the final blackout code from executing.

The smallprint: I take no responsibility for any security related risks you take by fiddling with any javascript in any of the above described ways or otherwise.

Enjoy!

Sparrow for iPhone… it’s coming

Apparently Sparrow are well on the way to offering their alternative to the much-loved(?) native iOS mail client. See for yourself…

In the recent months Sparrow for Mac has become my email client of choice. It’s a great example of an application written with the user in mind: it has a lovely UX; (almost) full Gmail functionality; and spurts regular update goodies.

Following this teaser on their blog I started to wonder: do we really need Sparrow for iPhone? My personal conclusions is that there is a gap for Sparrow to fill on the iOS devices! There are a small set of niggles I have with the way I can hook up Apple’s native Mail app with my Gmail account. I’ve currently got my iPhone hooked up to Gmail as an Exchange server account on my device via GoogleSync and I know some of the below can be solved using other methods but I have yet to find something that does everything well. It’s also worth noting that I haven’t tried iCloud and don’t really intend to ;)

  1. Support two-way synchronisation of sent mail. That is, if I send a mail on my iPhone it does not appear in my other clients.
  2. Proper deletion of mail. Moving an item to trash on the iPhone will archive it in Gmail. I know that this is configurable with the IMAP version but there are plenty of reasons why not to go down that route. Also it would be nice to have the option each time; something that the Sparrow Mac app has done nicely.
  3. Seamless multiple email addresses. It would be nice to be able to add one Gmail account to my iPhone and still be able to send mail from the other outgoing addresses it might use
  4. Assuming that 3 is implemented then multiple signatures.

Simply, if Sparrow can plug all these holes in their mobile client it will certainly win my vote.

Sparrow for iPhone

The Padintosh Retro iPad2 Case (via oliphillips)

The Padintosh Retro iPad2 Case (via oliphillips)

(via oliphillips)

Spotify: 1 million plays, £108 return (via The Independent) →

<controversial_comment>
    Perhaps Spotify users are hurting the
    music industry almost as much as piracy?
</controversial_commen>

HashMaps and primality — when & why?

Recently I was posed an interesting question during an interview for a graduate software engineering position. It would be unfair to say which company this was and so I will cryptic-crossword-clue-ify the name by saying finished novel before resounding characteristic of my stride. Anyway(!), I thought I’d share my thoughts on a particular (perhaps bogus) question from that experience.

So we got talking about the inner guts of how a HashMap might work. We talked about a (deliberately) naïve approach to the hash function which would take the reference of the object—an integer, r—and put it in bucket number n where n = abs(r) (mod N) where N is the number of buckets in the implementation. The question posed was:

What would be a suitable choice for N, the number of buckets in the Map?

We talked about it a bit and didn’t get very far until I was led to the answer that choosing N such that it is prime would be the best choice. At this point the other interviewer pipes up and exclaims that this isn’t useful or correct which got me thinking about whether choosing N prime makes any difference in minimising the number of collisions produced by our hash function. My gut was that I agreed with the objection to the question.

I went home and put my thinking hat on and came to a conclusion.

Read More

Getting me a set of custom moulded monitors ;) Win! #fb

Getting me a set of custom moulded monitors ;) Win! #fb

Term’s over; begin the (non-)vacation

Well thus ends my final Michaelmas term. I think that in future years I may come to miss October’s sudden onslaught of Freshers’ Flu but not much else. It’s been a manically busy period this time round with project proposals, dissertation work and careers fairs to boot! Not to mention the following pletherer of lecture courses which, whilst academically interesting, have questionable value to what I’ll probably end up doing for a job. Can’t really see myself knee-deep in qubits anytime soon which renders my Quantum Computing course a bit suspect and Denotational Semantics (next term) are just a little too ivory-tower for my liking—Although I did quite quite enjoy all the lovely greek that came with the polymorphic lambda calculus in this term’s Type Theory course:

So, on the subject of jobs. It really has come to that point. The point where, as a soon-to-be-graduate, I hope and pray that my hard work and well-earned debt will actually get me some employment in what is a pretty tough economic climate. Applications have already gone off—yikes—and I’m just gonna leave it up to God.

However, as many of my peers have been attending interviews I have come across some fun ridiculously pointless technical exercises that they have been set at interview. I honestly question how they can tell how fit you are for a role based on really anal puzzles such as the following:

Observe the following failed attempt to print Hello 20 times:

1  int n = 20;
2  int i;
3  for (i = 0; i < n; i--) {
4      printf("Hello");
5  }

The following code can be modified to produce the required output by changing a single character (adding, removing or substituting). Find three different ways to do this.

Now I need to be fair and actually say that correctly providing the solutions to this does show an ability to quickly debug, and knowledge of C (particularly for one of the solutions). For those of you who want to know, the solutions all involve modifying a character on line 3 and any of the following will do the trick:

3  for (i = 0;  i < n; n--)

3  for (i = 0; -i < n; i--)

3  for (i = 0;  i + n; i--)

No doubt that when I have had my interviews I’ll be able to share some equally dull programming puzzles. Bet you can’t wait, right?

Anyway, just got to really break the back of my disseration over the Christmas period, endure two more terms of lectures, drudge through the summer exams and then it will all be over! I’ll finally be Si Beaumont B.A.

P.S. It’s not worth asking why my Computer Science degree is a B.A. 

Hollywood vs real life hacker&#8230;

Hollywood vs real life hacker…

(Source: kevinisretro, via myconsole)

What really happened to Stone Henge?
myconsole:

I knew it

What really happened to Stone Henge?

myconsole:

I knew it

(Source: seriousjumprole)

TAGS:funny/geek/

Ask