Register a SA Forums Account here!
JOINING THE SA FORUMS WILL REMOVE THIS BIG AD, THE ANNOYING UNDERLINED ADS, AND STUPID INTERSTITIAL ADS!!!

You can: log in, read the tech support FAQ, or request your lost password. This dumb message (and those ads) will appear on every screen until you register! Get rid of this crap by registering your own SA Forums Account and joining roughly 150,000 Goons, for the one-time price of $9.95! We charge money because it costs us money per month for bills, and since we don't believe in showing ads to our users, we try to make the money back through forum registrations.
 
  • Post
  • Reply
Vulture Culture
Jul 14, 2003

I was never enjoying it. I only eat it for the nutrients.
Never has a single empty method call made me want to hit something so badly.

code:
$self->maybeTakeUserFromForm();

Adbot
ADBOT LOVES YOU

Vulture Culture
Jul 14, 2003

I was never enjoying it. I only eat it for the nutrients.

such a nice boy posted:

I walked over to my manager's office and showed him the code. His jaw almost hit the ground.
I hope you guys have code review policies in place now. :)

Vulture Culture
Jul 14, 2003

I was never enjoying it. I only eat it for the nutrients.

necrobobsledder posted:

I was working with this one person that would make research report results in an HTML file in Netscape Composer. I saw her load up the stuff in the browser and was wondering why it was taking about 20 seconds to load on a really beefy UltraSPARC workstation. Eventually she sent me the actual report for me to look at and what I saw was that. I wrote a Perl script to filter out those nbsp elements and the file shrunk from about 15 MB to about 100KB. She has a PhD in electrical engineering and is an IEEE fellow. The worst part is that she's supposed to know Perl pretty well since that's what half her experiments were in and know a bit about HTML. Ugh....
Scientists do not know Perl

Vulture Culture
Jul 14, 2003

I was never enjoying it. I only eat it for the nutrients.

Ryouga Inverse posted:

Anyway it isn't like you're going to forget which is which. I hope.
Unless you're a shell scripter.

Vulture Culture
Jul 14, 2003

I was never enjoying it. I only eat it for the nutrients.
Awk basically would have disappeared years ago if cut was able to handle multi-character delimiters

Vulture Culture
Jul 14, 2003

I was never enjoying it. I only eat it for the nutrients.

Mustach posted:

Cut is great if you only want to cut out fields, but I usually want to output things in more interesting ways.
Anything actually interesting is too complicated for awk anyway.

Vulture Culture
Jul 14, 2003

I was never enjoying it. I only eat it for the nutrients.

thel posted:

code:
SharedUtils.getFirstWord = function(str) {
  if (str.indexOf(' ') < 0) {
    return str;
  }
  for(var i = 0; i <str.length; i++){
    if(str.charAt(i) == ' '){
      return str.substring(0,i);
    }
  }
}
variables is basically just another word for loop counter

Vulture Culture
Jul 14, 2003

I was never enjoying it. I only eat it for the nutrients.

A A 2 3 5 8 K posted:

Putting an article on a web site has always been one of the hardest problems to solve in computer science.
this is my entire job

Vulture Culture
Jul 14, 2003

I was never enjoying it. I only eat it for the nutrients.

Fehler posted:

code:
typedef double real;
const real two = (real)2;
const real pi = 3.141592653589793;
This project is gonna be fun!
I'm curious what they're doing that demands pi to that precision but still uses IEEE floats

Adbot
ADBOT LOVES YOU

Vulture Culture
Jul 14, 2003

I was never enjoying it. I only eat it for the nutrients.
This code just turned up in some code I'm writing to integrate Crossroads.js with Backbone :(

code:
// Trust me, works great!
Router.extend = Backbone.Model.extend;

  • 1
  • 2
  • 3
  • 4
  • 5
  • Post
  • Reply