Nerdy jokes

Ah … well, I guess I am even slower. I wasn’t getting the Jerry Lewis, but I was close with “lousy”.

Two guys are flying a small airplane over Seattle. It is dark, rainy and foggy, and they have become disoriented and low on fuel. Their radio is not working. It is getting desperate. They need to get to the airport to land.

The see a large tall building, one row of offices lit up. The pilot signals in Morse code with a flashlight: “Where are we?” Someone in the office signals back immediately

The pilot sees the answer, flies right over to Lake Washington, heads south, and lands at the airport moments later.

His friend says, “Wow, they must have given you great directions.”

The pilot says, “Actually not. When I asked them where I was, they said “You are in a helicopter.” Friend says, “How did you know where to go?”

I knew it was the “Help” department at Microsoft. From there I knew my way.

This is very old and very long, but what the hell: The Evolution of a Programmer:

High School

10 PRINT “HELLO WORLD”
20 END

First year in College

program Hello(input, output)
begin
writeln(‘Hello World’)
end.

Senior year in College

(defun hello
(print
(cons 'Hello (list 'World))))

New professional

#include <stdio.h>
void main(void)
{
char *message = {"Hello ", “World”};
int i;

for(i = 0; i &lt; 2; ++i)
  printf("%s", message*);
printf("

");
}

Seasoned professional

#include <iostream.h>
#include <string.h>

class string
{
private:
int size;
char *ptr;

public:
string() : size(0), ptr(new char(’\0’)) {}

string(const string &s) : size(s.size)
{
  ptr = new char[size + 1];
  strcpy(ptr, s.ptr);
}

~string()
{
  delete [] ptr;
}

friend ostream &operator &lt;&lt;(ostream &, const string &);
string &operator=(const char *);

};

ostream &operator<<(ostream &stream, const string &s)
{
return(stream << s.ptr);
}

string &string:: operator=(const char *chrs)
{
if (this != &chrs)
{
delete ptr;
size = strlen(chrs);
ptr = new char[size + 1];
strcpy(ptr, chrs);
}
return(*this);
}

int main()
{
string str;

str = "Hello World";
cout &lt;&lt; str &lt;&lt; endl;

return(0);

}

Master Programmer

[
uuid(2573F8F4-CFEE-101A-9A9F-00AA00342820)
]
library LHello
{
// bring in the master library
importlib(“actimp.tlb”);
importlib(“actexp.tlb”);

  // bring in my interfaces
  #include "pshlo.idl"

  [
  uuid(2573F8F5-CFEE-101A-9A9F-00AA00342820)
  ]
  cotype THello

{
interface IHello;
interface IPersistFile;
};
};

[
exe,
uuid(2573F890-CFEE-101A-9A9F-00AA00342820)
]
module CHelloLib
{

  // some code related header files
  importheader(&lt;windows.h&gt; );
  importheader(&lt;ole2.h&gt; );
  importheader(&lt;except.hxx&gt; );
  importheader("pshlo.h");
  importheader("shlo.hxx");
  importheader("mycls.hxx");

  // needed typelibs
  importlib("actimp.tlb");
  importlib("actexp.tlb");
  importlib("thlo.tlb");

  [
  uuid(2573F891-CFEE-101A-9A9F-00AA00342820),
  aggregatable
  ]
  coclass CHello

{
cotype THello;
};
};

#include “ipfix.hxx”

extern HANDLE hEvent;

class CHello : public CHelloBase
{
public:
IPFIX(CLSID_CHello);

  CHello(IUnknown *pUnk);
  ~CHello();

  HRESULT  __stdcall PrintSz(LPWSTR pwszString);

private:
static int cObjRef;
};

#include <windows.h>
#include <ole2.h>
#include <stdio.h>
#include <stdlib.h>
#include “thlo.h”
#include “pshlo.h”
#include “shlo.hxx”
#include “mycls.hxx”

int CHello::cObjRef = 0;

CHello::CHello(IUnknown *pUnk) : CHelloBase(pUnk)
{
cObjRef++;
return;
}

HRESULT __stdcall CHello::PrintSz(LPWSTR pwszString)
{
printf("%ws
", pwszString);
return(ResultFromScode(S_OK));
}

CHello::~CHello(void)
{

// when the object count goes to zero, stop the server
cObjRef–;
if( cObjRef == 0 )
PulseEvent(hEvent);

return;
}

#include <windows.h>
#include <ole2.h>
#include “pshlo.h”
#include “shlo.hxx”
#include “mycls.hxx”

HANDLE hEvent;

int _cdecl main(
int argc,
char * argv
) {
ULONG ulRef;
DWORD dwRegistration;
CHelloCF *pCF = new CHelloCF();

hEvent = CreateEvent(NULL, FALSE, FALSE, NULL);

// Initialize the OLE libraries
CoInitializeEx(NULL, COINIT_MULTITHREADED);

CoRegisterClassObject(CLSID_CHello, pCF, CLSCTX_LOCAL_SERVER,
REGCLS_MULTIPLEUSE, &dwRegistration);

// wait on an event to stop
WaitForSingleObject(hEvent, INFINITE);

// revoke and release the class object
CoRevokeClassObject(dwRegistration);
ulRef = pCF->Release();

// Tell OLE we are going away.
CoUninitialize();

return(0); }

extern CLSID CLSID_CHello;
extern UUID LIBID_CHelloLib;

CLSID CLSID_CHello = { /* 2573F891-CFEE-101A-9A9F-00AA00342820 */
0x2573F891,
0xCFEE,
0x101A,
{ 0x9A, 0x9F, 0x00, 0xAA, 0x00, 0x34, 0x28, 0x20 }
};

UUID LIBID_CHelloLib = { /* 2573F890-CFEE-101A-9A9F-00AA00342820 */
0x2573F890,
0xCFEE,
0x101A,
{ 0x9A, 0x9F, 0x00, 0xAA, 0x00, 0x34, 0x28, 0x20 }
};

#include <windows.h>
#include <ole2.h>
#include <stdlib.h>
#include <string.h>
#include <stdio.h>
#include “pshlo.h”
#include “shlo.hxx”
#include “clsid.h”

int _cdecl main(
int argc,
char * argv
) {
HRESULT hRslt;
IHello *pHello;
ULONG ulCnt;
IMoniker * pmk;
WCHAR wcsT[_MAX_PATH];
WCHAR wcsPath[2 * _MAX_PATH];

// get object path
wcsPath[0] = ‘\0’;
wcsT[0] = ‘\0’;
if( argc > 1) {
mbstowcs(wcsPath, argv[1], strlen(argv[1]) + 1);
wcsupr(wcsPath);
}
else {
fprintf(stderr, "Object path must be specified
");
return(1);
}

// get print string
if(argc > 2)
mbstowcs(wcsT, argv[2], strlen(argv[2]) + 1);
else
wcscpy(wcsT, L"Hello World");

printf("Linking to object %ws
", wcsPath);
printf("Text String %ws
", wcsT);

// Initialize the OLE libraries
hRslt = CoInitializeEx(NULL, COINIT_MULTITHREADED);

if(SUCCEEDED(hRslt)) {

  hRslt = CreateFileMoniker(wcsPath, &pmk);
  if(SUCCEEDED(hRslt))

hRslt = BindMoniker(pmk, 0, IID_IHello, (void **)&pHello);

  if(SUCCEEDED(hRslt)) {

// print a string out
pHello->PrintSz(wcsT);

Sleep(2000);
ulCnt = pHello->Release();
}
else
printf(“Failure to connect, status: %lx”, hRslt);

  // Tell OLE we are going away.
  CoUninitialize();
  }

return(0);
}

Apprentice Hacker

#!/usr/local/bin/perl
msg="Hello, world. "; if (#ARGV >= 0) {
while(defined($arg=shift(@ARGV))) {
$outfilename = $arg;
open(FILE, “>” . $outfilename) || die "Can’t write arg: !
";
print (FILE $msg);
close(FILE) || die "Can’t close arg: !
";
}
} else {
print ($msg);
}
1;

Experienced Hacker

#include <stdio.h>
#define S "Hello, World
"
main(){exit(printf(S) == strlen(S) ? 0 : 1);}

Seasoned Hacker

% cc -o a.out ~/src/misc/hw/hw.c
% a.out

Guru Hacker

% echo “Hello, world.”

New Manager

10 PRINT “HELLO WORLD”
20 END

Middle Manager

mail -s “Hello, world.” bob@b12
Bob, could you please write me a program that prints “Hello,
world.”?
I need it by tomorrow.
^D

Senior Manager

% zmail jim
I need a “Hello, world.” program by this afternoon.

Chief Executive

% letter
letter: Command not found.
% mail
To: ^X ^F ^C
% help mail
help: Command not found.
% damn!
!: Event unrecognized
% logout

Understanding Engineers - Take one: Two engineering students were walking across campus when one said, “Where did you get such a great bike?”

The second engineer replied, "Well, I was walking along yesterday minding my own business when a beautiful woman rode up on this bike. She threw the bike to the ground, took off all her clothes and said, “Take what you want.”

"The second engineer nodded approvingly, “Good choice. The clothes probably wouldn’t have fit .”
Understanding Engineers - Take Two: To the optimist, the glass is half full. To the pessimist, The glass is half empty. To the engineer, the glass is twice as big as it needs to be.
Understanding Engineers - Take Three: A pastor, a doctor and an engineer were waiting one morning for a particularly slow group of golfers. The engineer fumed, “What’s with these guys? We must have been waiting for 15 minutes!”

The doctor chimed in, “I don’t know, but I’ve never seen such ineptitude!”

The pastor said, “Hey, here comes the greens keeper. Let’s have a word with him.” “Hi George! Say, what’s with that group ahead of us? They’re rather slow, aren’t they?”

The greens keeper replied, “Oh, yes, that’s a group of blind firefighters. They lost their sight saving our clubhouse from a fire last year, so we always let them play for free anytime.”

The group was silent for a moment. The pastor said, “That’s so sad. I think I’ll say a special prayer for them tonight.”

The doctor said, “Good idea. And I’m going to contact my Ophthalmologist buddy and see if there’s anything he can do for them.”

The engineer said, “Why can’t these guys play at night?”
Understanding Engineers - Take Four: What is the difference between Mechanical Engineers and Civil Engineers? Mechanical Engineers build weapons and Civil Engineers build targets.
Understanding Engineers - Take Five: The graduate with a Science degree asks, “Why does it work?” The graduate with an Engineering degree asks, “How does it work?” The graduate with an Accounting degree asks, “How much will it cost?” The graduate with an Arts degree asks, “Do you want fries with that?”
Understanding Engineers - Take Six: Three engineering students were gathered together discussing the possible designers of the human body. One said, “It was a mechanical engineer. Just look at all the joints.”

Another said, “No, it was an electrical engineer. The nervous system has many thousands of electrical connections.”

The last one said, “Actually it was a civil engineer. Who else would run a toxic waste pipeline through a recreational area?”
Understanding Engineers - Take Seven: Normal people believe that if it ain’t broke, don’t fix it. Engineers believe that if it ain’t broke, it doesn’t have enough features yet.
Understanding Engineers - Take Eight: An architect, an artist and an engineer were discussing whether it was better to spend time with the wife or a mistress. The architect said he enjoyed time with his wife, building a solid foundation for an enduring relationship. The artist said he enjoyed time with his mistress, because the passion and mystery he found there.

The engineer said, “I like both.” Both? “Yeah. If you have a wife and a mistress, they will each assume you are spending time with the other woman, and you can go to the lab and get some work done.”
Understanding Engineers - Take Nine: An engineer was crossing a road one day when a frog called out to him and said, “If you kiss me, I’ll turn into a beautiful princess.” He bent over, picked up the frog and put it in his pocket. The frog spoke up again and said, “If you kiss me and turn me back into a beautiful princess, I will stay with you for one week.”

The engineer took the frog out of his pocket, smiled at it and returned it to the pocket. The frog then cried out, “If you kiss me and turn me back into a princess, I’ll stay with you and do ANYTHING you want.”

Again the engineer took the frog out, smiled at it and put it back into his pocket. Finally, the frog asked, “What is the matter? I’ve told you I’m a beautiful princess, and that I’ll stay with you for a week and do anything you want. Why won’t you kiss me?” The engineer said, “Look, I’m an engineer. I don’t have time for a girlfriend, but a talking frog, now that’s cool”.

This short quiz from Andersen Consulting will help you understand your thinking style better. The questions aren’t difficult and you can scroll down for the answers.

  1. How do you put a giraffe into a refrigerator?

  2. How do you put an elephant into a refrigerator?

  3. The Lion King is hosting an animal conference; all the animals attend except one. Which animal does not attend?

  4. There is a river you must cross. But it is inhabited by crocodiles. How do you manage it?

Answers:
Question #1: Correct Answer: Open the refrigerator, put in the giraffe and close the door. This question tests whether you tend to do simple things in an overly complicated way.

Question #2: Wrong Answer: Open the refrigerator, put in the elephant and close the refrigerator.
Correct Answer: Open the refrigerator, take out the giraffe, put in the elephant and close the door. This tests your ability to think through the repercussions of your actions.

Question #3 Correct Answer: The Elephant. The Elephant is in the refrigerator! This tests your memory.

Question #4: Correct Answer: You swim across. All the crocodiles are attending the Animal Meeting! This tests whether you learn quickly from your mistakes.

According to Andersen Consulting Worldwide, around 90% of the professionals they tested got all questions wrong. But many preschoolers got several correct answers. Andersen Consulting says this conclusively disproves the theory that most professionals have the brains of four-year olds.