Allegro.cc - Online Community

Allegro.cc Forums » Off-Topic Ordeals » Programmers day

This thread is locked; no one can reply to it. rss feed Print
 1   2 
Programmers day
clovekx
Member #3,479
April 2003
avatar

It's programmers day today. Do you celebrate? Unfortunately I have to work manualy now. (:

Trezker
Member #1,739
December 2001
avatar

Where's the site that claims this?

Krzysztof Kluczek
Member #4,191
January 2004
avatar

Here! ;) And how 256th day of a year wouldn't be programmer's day? :)

Happy Bir^H^H^H Programmer's Day! :)

Dennis
Member #1,090
July 2003
avatar

teachersparadise.com said:

Programmer's day is a whimsical "holiday" on the 256th day of the year celebrated mostly by computer programmers (reason: 256 = 2 to the power of 8 = the number of values representable in a byte of data).
Traditions include drinking, behaving silly, coding silly programs, mini computer games, playing with old computers, etc.

So how is this different to any other day?
but well:
:)Happy programmer's day!:)

Johan Halmén
Member #1,550
September 2001

It might be the 256th day of the year, but a real programmer calls it the 255 day.
Tomorrow you all have to tell in this thread how you celebrated the day.

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Years of thorough research have revealed that the red "x" that closes a window, really isn't red, but white on red background.

Years of thorough research have revealed that what people find beautiful about the Mandelbrot set is not the set itself, but all the rest.

amarillion
Member #940
January 2001
avatar

Quote:

So how is this different to any other day?

Those are unprogrammer's days

OICW
Member #4,069
November 2003
avatar

Well lets celebrate

[My website][CppReference][Pixelate][Allegators worldwide][Who's online]
"Final Fantasy XIV, I feel that anything I could say will be repeating myself, so I'm just gonna express my feelings with a strangled noise from the back of my throat. Graaarghhhh..." - Yahtzee
"Uhm... this is a.cc. Did you honestly think this thread WOULDN'T be derailed and ruined?" - BAF
"You can discuss it, you can dislike it, you can disagree with it, but that's all what you can do with it"

Michael Jensen
Member #2,870
October 2002
avatar

Quote:

Those are unprogrammer's days

nice.

Quote:

but a real programmer calls it the 255 day.

if it's on the 255th day, then jan 1st would be day 0 -- hence it's still today (assuming jan 1st is considered day 1 in the 256 version)

Happy programmer's day.

OICW
Member #4,069
November 2003
avatar

Well lets celebrate both days

[My website][CppReference][Pixelate][Allegators worldwide][Who's online]
"Final Fantasy XIV, I feel that anything I could say will be repeating myself, so I'm just gonna express my feelings with a strangled noise from the back of my throat. Graaarghhhh..." - Yahtzee
"Uhm... this is a.cc. Did you honestly think this thread WOULDN'T be derailed and ruined?" - BAF
"You can discuss it, you can dislike it, you can disagree with it, but that's all what you can do with it"

Michael Jensen
Member #2,870
October 2002
avatar

They're both on the same day.

A J
Member #3,025
December 2002
avatar

whats a day got to do with it, half of us program at night.
and the other half program in the dark ;)

___________________________
The more you talk, the more AJ is right. - ML

Johan Halmén
Member #1,550
September 2001

Programmers and photographers do it in the dark! 8-)

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Years of thorough research have revealed that the red "x" that closes a window, really isn't red, but white on red background.

Years of thorough research have revealed that what people find beautiful about the Mandelbrot set is not the set itself, but all the rest.

khristina yer
Member #5,795
May 2005
avatar

Quote:

Programmers and photographers do it in the dark! 8-)

Is that becouse of how we look?

Billybob
Member #3,136
January 2003

while(!drunk)
     drink();

Onewing
Member #6,152
August 2005
avatar

I prefer:

while(!drunk || drunk)   
  drink();

//or

while()
  drink();

Yay! The tradition of silly coding on programmer's day!

------------
Solo-Games.org | My Tech Blog: The Digital Helm

Crazy Photon
Member #2,588
July 2002
avatar

while(1)
  drink();

-----
Resistance is NEVER futile...

Derezo
Member #1,666
April 2001
avatar

1#include <stdio.h>
2 
3enum
4 {
5 VERY_DRUNK, ALMOST_DRUNK, NOT_DRUNK,
6 BEER, COFFEE, WATER
7 };
8 
9class Programmer
10 {
11 public:
12 
13 int IsDrunk();
14 int Drink(int);
15 Programmer()
16 {
17 alertness = 20;
18 beers = 24;
19 blood_alcohol = 0;
20 printf("The programmer awakens.\n");
21 }
22 private:
23 int alertness;
24 int beers;
25 float blood_alcohol;
26 };
27 
28int Programmer::IsDrunk()
29 {
30 if(blood_alcohol > 0.16f)
31 {
32 // getting there
33 return VERY_DRUNK;
34 }
35 if(blood_alcohol > 0.06f)
36 {
37 return ALMOST_DRUNK;
38 }
39 return NOT_DRUNK;
40 }
41 
42int Programmer::Drink(int liquid)
43 {
44 switch(liquid)
45 {
46 case BEER:
47 if(beers <= 0)
48 {
49 if(beers == 0)
50 {
51 beers = -1;
52 printf("You ran out of beer, man.\n");
53 }
54 return 0;
55 }
56 blood_alcohol += 0.02f;
57 beers--;
58 alertness-=2;
59 printf("Your alertness decreases as you drink a beer.\n");
60 break;
61 
62 case WATER:
63 if(blood_alcohol > 0)
64 blood_alcohol -= 0.01f;
65 alertness++;
66 printf("The water helps you regain your alertness.\n");
67 break;
68 
69 case COFFEE:
70 if(blood_alcohol > 0)
71 blood_alcohol -= 0.03f;
72 alertness += 3;
73 printf("You feel refreshed from a cup of warm coffee!\n");
74 break;
75 
76 default:
77 break;
78 }
79 return 1;
80 }
81 
82int main()
83 {
84 Programmer *p = new Programmer;
85 int programmers_day = 0xFF;
86 
87 while(programmers_day)
88 {
89 if(p->IsDrunk() == VERY_DRUNK) break;
90 else
91 p->Drink(BEER);
92 }
93 
94 printf("Too much beer... you're wasted.\n");
95 p->Drink(WATER);
96
97 while(p->IsDrunk() != NOT_DRUNK)
98 {
99 p->Drink(COFFEE);
100 }
101 
102 printf("You've sobered up pretty good. Go code.\n");
103
104 delete p;
105 return 0;
106 }

I should get to work.
[edit: Fixed some bugs, first. ;D]

"He who controls the stuffing controls the Universe"

BAF
Member #2,981
December 2002
avatar

while(1)
    code();

Breakman79
Member #1,236
April 2001
avatar

I guess it was just plain and simple destiny that I became a programmer then since my birthday is also today.

Dennis
Member #1,090
July 2003
avatar

Happy B-Day Breakman79.:)

Coder Simulator:

while(1)
  cout << "He is idle...";

Felipe Maia
Member #6,190
September 2005
avatar

void program() {
    while(crazyness < MONKEY) {
        code();
    }
    psychoDream();
    program();
}

Crazy Photon
Member #2,588
July 2002
avatar

Quote:

my birthday is also today

Felíz cumpleaños!! :)

gives keg of beer as present ;)

-----
Resistance is NEVER futile...

Chris Katko
Member #1,881
January 2002
avatar

Pfft. I celebrate programmer's day every 18,446,744,073,709,551,616th day. Get with the program you bunch of 8-bit antiques.

p.s. The 8-bit programmer's day would still be on the 256th day, because zero is not a day (which makes it interval data!).

-----sig:
“Programs should be written for people to read, and only incidentally for machines to execute.” - Structure and Interpretation of Computer Programs
"Political Correctness is fascism disguised as manners" --George Carlin

Thomas Fjellstrom
Member #476
June 2000
avatar

Chris, the First day starts at 0, and ends just before 1, so 0 is a day.

typedef Day *Week[7];
Week this_week;
this_week[0] = new Day("Today");

--
Thomas Fjellstrom - [website] - [email] - [Allegro Wiki] - [Allegro TODO]
"If you can't think of a better solution, don't try to make a better solution." -- weapon_S
"The less evidence we have for what we believe is certain, the more violently we defend beliefs against those who don't agree" -- https://twitter.com/neiltyson/status/592870205409353730

Archon
Member #4,195
January 2004
avatar

It should be:

return(WASTED);

Where the variable WASTED is defined in <stdrink.h>

 1   2 


Go to: