# (c) 2005 by Lousy Coder

**URL:** <https://boards.straightdope.com/t/c-2005-by-lousy-coder/322722>\
**Category:** The BBQ Pit\
**Created:** [September 21, 2005, 3:48pm UTC](https://boards.straightdope.com/t/c-2005-by-lousy-coder/322722 "2005-09-21T15:48:41Z")\
**Posts on this page:** 20\
**Page:** 2

<div class="post-metadata">

**Author:** ![OleOneEye](https://avatars.discourse-cdn.com/v4/letter/o/f14d63/32.png) [@OleOneEye](https://boards.straightdope.com/u/OleOneEye)\
**Post date:** [September 22, 2005, 1:35am UTC](https://boards.straightdope.com/t/c-2005-by-lousy-coder/322722/21 "2005-09-22T01:35:42Z")

</div>

> [@Mbossa](#):
>
> Undefined variable: n  
> 😛

Not to mention, public data member _length_. Accessors: they’re not just for breakfast anymore.

---

<div class="post-metadata">

**Author:** ![Metacom](https://avatars.discourse-cdn.com/v4/letter/m/ecae2f/32.png) [@Metacom](https://boards.straightdope.com/u/Metacom)\
**Post date:** [September 22, 2005, 1:53am UTC](https://boards.straightdope.com/t/c-2005-by-lousy-coder/322722/22 "2005-09-22T01:53:57Z")

</div>

> [@ultrafilter](#):
>
> So do it the modern way:
> 
> ```auto
> 
> printf( "%s
> ", ( postCount > 2000 ) ? "I agree!" : "This thread is stupid!" );
> 
> ```

How last millenium. 😉

```auto

System.out.println((postCount > 2000) ? "I agree!" : "This thread is stupid!");

```

Of course, the _best_ way to do it is:

```auto

(princ (if (> post-count 2000) "I agree!" "This thread is stupid!"))

```

but has a Java monkey, I can’t say that.

---

<div class="post-metadata">

**Author:** ![fluiddruid](https://avatars.discourse-cdn.com/v4/letter/f/c2a13f/32.png) [@fluiddruid](https://boards.straightdope.com/u/fluiddruid)\
**Post date:** [September 22, 2005, 2:28am UTC](https://boards.straightdope.com/t/c-2005-by-lousy-coder/322722/23 "2005-09-22T02:28:45Z")

</div>

> [@CaveMike](#):
>
> First off, line #10 is using a global variable… [etc]

Guh, er… I majored in history, y’see, I just remembered BASIC from those science magazines I got as a kid. You know, where they sent you the program you could type in yourself at home…

And… your criticisms… are probably… quite… er… … apt… and, uh… variable… localized… dynamic threshold…

[scratches head and furrows brow]

This thread is stupid!!!

---

<div class="post-metadata">

**Author:** ![dre2xl](https://avatars.discourse-cdn.com/v4/letter/d/34f0e0/32.png) [@dre2xl](https://boards.straightdope.com/u/dre2xl)\
**Post date:** [September 22, 2005, 2:43am UTC](https://boards.straightdope.com/t/c-2005-by-lousy-coder/322722/24 "2005-09-22T02:43:27Z")

</div>

Seriously, I was opening it up to see you blast some actual, err, _code_. Not what someone chose to put in their comments, unless it was something like…

int x = 1; // set integer x to 1

($\_\>=2000) ? print “This thread is stupid!” : else system “sudo rm -rf /”;

---

<div class="post-metadata">

**Author:** ![TJdude825](https://avatars.discourse-cdn.com/v4/letter/t/dec6dc/32.png) [@TJdude825](https://boards.straightdope.com/u/TJdude825)\
**Post date:** [September 22, 2005, 7:25am UTC](https://boards.straightdope.com/t/c-2005-by-lousy-coder/322722/25 "2005-09-22T07:25:08Z")

</div>

> [@CaveMike](#):
>
> … Finally, what is up with the obnoxious code-bloat that is called line #40? END is implicit. Why increase your code size by 25%? We will want to deploy this code on a multitude of platforms including cell-phones, pixie sticks, and the Internet-enabled vibrator (a.k.a. iBrator).
> 
> Seriously, I know someone that needs to enroll in GW-Basic for Distributed, Extensible, Internationalizable Web Applications for Dumbos.
> 
> 🙂

I don’t know any coding, but the increase was only 33.33%. Removing the line would be a 25% decrease, but the code before “END” was three lines, so one line is 33.33%.

That’s all.

---

<div class="post-metadata">

**Author:** ![Declan](https://avatars.discourse-cdn.com/v4/letter/d/ecae2f/32.png) [@Declan](https://boards.straightdope.com/u/Declan)\
**Post date:** [September 22, 2005, 9:18am UTC](https://boards.straightdope.com/t/c-2005-by-lousy-coder/322722/26 "2005-09-22T09:18:27Z")

</div>

GOTO post one

Declan

---

<div class="post-metadata">

**Author:** ![Malacandra](https://avatars.discourse-cdn.com/v4/letter/m/45deac/32.png) [@Malacandra](https://boards.straightdope.com/u/Malacandra)\
**Post date:** [September 22, 2005, 9:31am UTC](https://boards.straightdope.com/t/c-2005-by-lousy-coder/322722/27 "2005-09-22T09:31:37Z")

</div>

/_rexx_/

arg bothered .

if bothered then say ‘This thread is stupid’

exit

---

<div class="post-metadata">

**Author:** ![ouryL](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/ouryl/32/6067_2.png) [@ouryL](https://boards.straightdope.com/u/ouryL)\
**Post date:** [September 22, 2005, 8:53pm UTC](https://boards.straightdope.com/t/c-2005-by-lousy-coder/322722/28 "2005-09-22T20:53:31Z")

</div>

Of course lousy coders copywrite their code.  
Rude people who knock you down call you rude.  
Robbers call their rich victims thieves…

---

<div class="post-metadata">

**Author:** ![GorillaMan](https://avatars.discourse-cdn.com/v4/letter/g/50afbb/32.png) [@GorillaMan](https://boards.straightdope.com/u/GorillaMan)\
**Post date:** [September 22, 2005, 9:02pm UTC](https://boards.straightdope.com/t/c-2005-by-lousy-coder/322722/29 "2005-09-22T21:02:04Z")

</div>

> [@cricetus](#):
>
> And even if you did, you don’t own it. You were paid to write it, and it belongs to whoever paid for it.

I’m not sure copyright law is necessarily this simple. But hey, who cares.

:: reaches round to the back panel of the computer ::

Isn’t there a ‘break’ button here somewhere?

---

<div class="post-metadata">

**Author:** ![NurseCarmen](https://avatars.discourse-cdn.com/v4/letter/n/5daacb/32.png) [@NurseCarmen](https://boards.straightdope.com/u/NurseCarmen)\
**Post date:** [September 22, 2005, 9:24pm UTC](https://boards.straightdope.com/t/c-2005-by-lousy-coder/322722/30 "2005-09-22T21:24:13Z")

</div>

I just can’t seem to get past **Declan** ’s post.

---

<div class="post-metadata">

**Author:** ![lno](https://avatars.discourse-cdn.com/v4/letter/l/a8b319/32.png) [@lno](https://boards.straightdope.com/u/lno)\
**Post date:** [September 22, 2005, 9:30pm UTC](https://boards.straightdope.com/t/c-2005-by-lousy-coder/322722/31 "2005-09-22T21:30:50Z")

</div>

> [@NurseCarmen](#):
>
> I just can’t seem to get past **Declan** ’s post.

If a mod had edited **TJdude825** ’s post to include “GOTO post 27” at the end of it, I think I would have suffocated from laughter.

---

<div class="post-metadata">

**Author:** ![Gangster\_Octopus](https://avatars.discourse-cdn.com/v4/letter/g/a8b319/32.png) [@Gangster\_Octopus](https://boards.straightdope.com/u/Gangster_Octopus)\
**Post date:** [September 22, 2005, 9:44pm UTC](https://boards.straightdope.com/t/c-2005-by-lousy-coder/322722/32 "2005-09-22T21:44:31Z")

</div>

> [@Metacom](#):
>
> How last millenium. 😉
> 
> ```auto
> 
> System.out.println((postCount > 2000) ? "I agree!" : "This thread is stupid!");
> 
> ```
> 
> Of course, the _best_ way to do it is:
> 
> ```auto
> 
> (princ (if (> post-count 2000) "I agree!" "This thread is stupid!"))
> 
> ```
> 
> but has a Java monkey, I can’t say that.

Almost

```auto

! Program Auto SDMB Respond
! Created by Metacom
! Date: 21.09.2005
! 
! The purpose of this program is to auto-repsond to posts based on the post
! count of the original poster. If the Post count is less than a specified amount - 
! 2000 in this case - then the program creates a post, "I agree!" signifying
! agreement. If the post count is less than 2000, then the post created says
! "This thread is stupid!" indicating a general disagreement with the OP.
!

! Determine post count and the appropriate response

(princ (if (> post-count 2000) "I agree!" "This thread is stupid!"))

```

---

<div class="post-metadata">

**Author:** ![Cervaise](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/cervaise/32/16693_2.png) [@Cervaise](https://boards.straightdope.com/u/Cervaise)\
**Post date:** [September 23, 2005, 12:16am UTC](https://boards.straightdope.com/t/c-2005-by-lousy-coder/322722/33 "2005-09-23T00:16:18Z")

</div>

> [@lno](#):
>
> If a mod had edited **TJdude825** ’s post to include “GOTO post 27” at the end of it, I think I would have suffocated from laughter.

I think I would have preferred a GOSUB.

---

<div class="post-metadata">

**Author:** ![Mangetout](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/mangetout/32/19_2.png) [@Mangetout](https://boards.straightdope.com/u/Mangetout)\
**Post date:** [September 23, 2005, 12:26am UTC](https://boards.straightdope.com/t/c-2005-by-lousy-coder/322722/34 "2005-09-23T00:26:53Z")

</div>

> [@fluiddruid](#):
>
> 10 Postcount = Number of OP’s Posts  
> 20 If Postcount\>2000, Then Print “I agree!!!”  
> 30 If Postcount\<2000, Then Print “This thread is stupid!!!”  
> 40 END
> 
> (C) 2005 Fluiddruid, [fluiddruid@dontspamme.com](mailto:fluiddruid@dontspamme.com)

And if the post count is _exactly 2000_?

---

<div class="post-metadata">

**Author:** ![panamajack](https://avatars.discourse-cdn.com/v4/letter/p/47e85d/32.png) [@panamajack](https://boards.straightdope.com/u/panamajack)\
**Post date:** [September 23, 2005, 12:36am UTC](https://boards.straightdope.com/t/c-2005-by-lousy-coder/322722/35 "2005-09-23T00:36:50Z")

</div>

Man, you beat me to it. I was going to point out that with all these programmers modifying **Fluiddruid** ’s code, not one of them ported it correctly.

If it’s = 2000, you don’t post. Of course that means you can’t get your post count above 2000, but 2000’s a big enough post count, wouldn’t you aree?

---

<div class="post-metadata">

**Author:** ![Mbossa](https://avatars.discourse-cdn.com/v4/letter/m/73ab20/32.png) [@Mbossa](https://boards.straightdope.com/u/Mbossa)\
**Post date:** [September 23, 2005, 1:55am UTC](https://boards.straightdope.com/t/c-2005-by-lousy-coder/322722/36 "2005-09-23T01:55:57Z")

</div>

> [@Mangetout](#):
>
> And if the post count is _exactly 2000_?

…

---

<div class="post-metadata">

**Author:** ![wolf\_meister](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/wolf_meister/32/15202_2.png) [@wolf\_meister](https://boards.straightdope.com/u/wolf_meister)\
**Post date:** [September 23, 2005, 2:02am UTC](https://boards.straightdope.com/t/c-2005-by-lousy-coder/322722/37 "2005-09-23T02:02:51Z")

</div>

**cricetus**  
You talk about lousy coding and yet you don’t even use the **©** symbol _and_ you made a double posting? What do you think this is … 1960?

---

<div class="post-metadata">

**Author:** ![fluiddruid](https://avatars.discourse-cdn.com/v4/letter/f/c2a13f/32.png) [@fluiddruid](https://boards.straightdope.com/u/fluiddruid)\
**Post date:** [September 23, 2005, 10:57am UTC](https://boards.straightdope.com/t/c-2005-by-lousy-coder/322722/38 "2005-09-23T10:57:07Z")

</div>

> [@Mangetout](#):
>
> And if the post count is _exactly 2000_?

Hmmm. How about, “You wasted your 2,000th post on THIS?!”

---

<div class="post-metadata">

**Author:** ![Noone\_Special](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/noone_special/32/2863_2.png) [@Noone\_Special](https://boards.straightdope.com/u/Noone_Special)\
**Post date:** [September 23, 2005, 12:08pm UTC](https://boards.straightdope.com/t/c-2005-by-lousy-coder/322722/39 "2005-09-23T12:08:36Z")

</div>

> [@Cervaise](#):
>
> I think I would have preferred a GOSUB.

Old BASIC programmers don’t die. They just GOSUB without RETURN

---

<div class="post-metadata">

**Author:** ![Crotalus](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/crotalus/32/41_2.png) [@Crotalus](https://boards.straightdope.com/u/Crotalus)\
**Post date:** [September 23, 2005, 12:16pm UTC](https://boards.straightdope.com/t/c-2005-by-lousy-coder/322722/40 "2005-09-23T12:16:13Z")

</div>

COBOL, anyone?

IF POST-COUNT \> 2000  
DISPLAY ‘I AGREE!!!’  
ELSE  
IF POST-COUNT \< 2000  
DISPLAY ‘THIS THREAD IS STUPID!!!’  
ELSE  
NEXT SENTENCE  
END-IF  
END-IF.

[Previous page](https://boards.straightdope.com/t/c-2005-by-lousy-coder/322722.md?page=1)

[Next page](https://boards.straightdope.com/t/c-2005-by-lousy-coder/322722.md?page=3)
