Stories
Slash Boxes
Comments
NOTE: use Perl; is on undef hiatus. You can read content, but you can't post it. More info will be forthcoming forthcomingly.

All the Perl that's Practical to Extract and Report

use Perl Log In

Log In

[ Create a new account ]

chaoticset (2105)

chaoticset
  (email not shown publicly)
http://chaoticset.perlmonk.org/
AOL IM: chaoticset23 (Add Buddy, Send Message)
Yahoo! ID: illuminatus_foil (Add User, Send Message)

JAPH. (That's right -- I'm not Really Inexperienced any more.)

I'm not just here, I'm here [perlmonks.org], and here [javajunkies.org] too, I ramble randomly in my philosophical blog [blogspot.com] and my other blog [blogspot.com]. Soon I'll come in a convenient six-pack.

Journal of chaoticset (2105)

Saturday November 10, 2001
12:41 AM

Many Hours Later...

[ #1224 ]
...and it seems like nothing's done.

Scratch that, nothing *has* been done yet.

Okay, that's not exactly true.

I set up Apache again and made sure it worked. (Weirdness: saving the whole mess to CDROM apparently left it write-protected somehow, because when I copied the whole Apache Group directory back to the hard drive, that was the error I got: '...file "error.log" is read-only...' or somesuch. cleared it, cleared the other log, ran Apache, it worked.)

What else?

I wrote this function in my Works database:

#This is the rounding function. Where int would have had a
#big part of this program had Landry merely said, "Round
#down to whole dollars, and I won't want it any other way",
#instead, there is this. Rounding is what it does; to what
#values can be determined arbitrarily. For now, it's to
#the *nearest* dollar.
sub rounded {
if ($_[0] if ( ($_[0] return int ($_[0] + 1);
} else {
return int $_[0]; }
}

This function is going to have to be updated eventually, into a similar function that rounds to the nearest .25 cent value. (That is, 2.68 becomes 2.75, and 2.67 becomes 2.50.) No, it isn't a perfect system, but there's actually a reason for doing it instead of just rounding before storing these values in the STOCK file...

Eventually, the client wants to be able to decrement specific cards a specific value every time he updates the inventory. (That way, he can have card values going down every few days, or even several times over a single day, if he wants...but he doesn't *have* to.)

In the controls file, that behavior would be controlled by another value, tacked onto the end of the regular lines. A value from 0 to 1, expressing the percentage that specific card should go down.

During the transaction, there's no way for that value to change; but over the space of a few hours, customers might notice a significant change in the prices, or over a week or so. My client is convinced (as am I) that hits require a certain amount of variety; of believing you might catch a good deal; of believing that maybe it's still going down, maybe you can catch it before someone else, etc.

Oh, I know. Evil. Well, he's hoping to sell ad space on this thing eventually, so I get where he's coming from. (Desperation for money.)

Anyway, that's the function, why it's like that, and where it's going in the future.

I did a few other things, like pick up a FedEx package without knowing what building I was supposed to be at and driving aimlessly when I forgot I was going somewhere, but those are the things that I'll have documented evidence of tomorrow. I want to do a little more function stuff before I go to sleep, and then it's pillow time. Tomorrow is busy; gotta get SO to work, gotta get to the church bazaar my parents are involved in; gotta get Little Debbies.

I mean, I have Dew, but I don't have any Double Chocolate Swiss Rolls...no wonder I haven't been cranking any decent code out. :)

The Fine Print: The following comments are owned by whoever posted them. We are not responsible for them in any way.
 Full
 Abbreviated
 Hidden
More | Login | Reply
Loading... please wait.