Catch up on stories from the past week (and beyond) at the Slashdot story archive

 



Forgot your password?
typodupeerror
User Journal

Journal Journal: Trump vindicates damn_registrars 3 3

"Wisconsin is in turmoil," Trump told a boisterous crowd at a rally in Iowa. He pointed to the state's roads, schools and hospitals, which he said were all "a disaster."
Walker, who is leading polls in Iowa, remains one of Trump's biggest rivals in the race.
"I hear the only person beating me in Iowa is Scott Walker," he said. "I can't believe I'm in second place. Folks, will you please put me in first place so I feel better?"
Trump told the crowd Saturday that he had helped Walker win his race because he admired the candidate's "fight," but didn't know what he was fighting for. "I've been very nice to him," he said.
But after Walker's fundraising email went public, Trump declared: "I can finally attack."

I think Trump is a buffoon, but, if the Vichy GOP put up JEB, I'll cheerfully vote for His Donaldness.

User Journal

Journal Journal: GreaseMonkey scripts 4 4

I've been making use of GreaseMonkey for some time now. I found some scripts that i lie, namely Allow Password Remembering, Block youtube users, and Google Hit Hider by Domain. I've added a few of my own, Displaying Monk Levels and Checking Saint in our Book for ties, both for PerlMonks and now, Amazon Star percent to number.

I love Amazon Reviews, and those stars mean a lot to me. However, Amazon, in their great wisdom, decided to replace the useful numbers with useless percentages. Well, not useless, but compared to actual numbers, percents mean next to nothing. Who cares if 100% 5-star it, if that's only one person. I'd rather purchase a product with 80% 5-stars, but by a few hundred people. Sure, the number is on top, but who wants to do the math all the time?

To grab the number, the reviews page would have to be loaded for each star. So, i just did multiplication, which will be close enough. I guess the reviews page can get the actual number as opposed to multiplying, but this is good enough, and since it can be the same as the main product page which i did first, i'm not interested in putting in the effort to change it for the reviews page.

User Journal

Journal Journal: Hey, these retards are like the ones I work with 5 5

http://romancescams.org/ Scroll down to the quiz. The Yes/No choices are not represented by radio buttons (or some other single-selection-only UI element), but by checkboxes. So WTF does it mean if I check both Yes and No to a pretty much binary question.

Kind of like the morons at my work that represent an action with a checkbox. A checkbox represents state, a pushbutton advertises an available action. So we have checkboxes that then visually (along with their label) signal a certain state, even when the application is no longer in that state.

When I brought this up, and said a pushbutton would be more appropriate, I was told that technically I have a point, but that they don't care.

User Journal

Journal Journal: Google, my Hero! 6 6

Yeah, I said that.

Many, many moons ago, anyone that knows me that long might remember me asking about where to find a two-page advertisement that Sun Microsystems had put out some time around 1998. It had a picture of Sally Struthers and a caption that said something like "Thinking of running your critical apps on NT? Isn't there enough world suffering?"

Well, it's been found in the November 23, 1998 issue of InfoWorld, on pages 8 and 9.

Needless to say, I'm very happy. :)
User Journal

Journal Journal: Shout out to the Nematodes 25 25

I'd like to ask the worms on here to defend that scumbag Chisholm, but such would require vertebrae.

It is utterly clear that the special prosecutor has employed theories of law that do not exist in order to investigate citizens who were wholly innocent of any wrongdoing. In other words, the special prosecutor was the instigator of a "perfect storm" of wrongs that was visited upon the innocent Unnamed Movants and those who dared to associate with them. It is fortunate, indeed, for every other citizen of this great State who is interested in the protection of fundamental liberties that the special prosecutor chose as his targets innocent citizens who had both the will and the means to fight the unlimited resources of an unjust prosecution.

I rarely feel genuine shame over my country, but this is an example of a source thereof.

User Journal

Journal Journal: Well if it's about health care, then it's okay 2 2

(Who could be against something that's just part of health care?)

In "health care", "patients" sometimes want to "donate" "tissue" to scientific research...

I used to think the death panels in our future would be just about controlling costs. But now I see that there'll also be the "humanitarian undertaking" part of it.

p.s. I'm not an "anti-vaxxer", but if the government can require you to put things in your body it means they own your body more than you do. They can decide it's time for you to give up your organs, because "medical breakthroughs".

User Journal

Journal Journal: yum, feet

So in Panera tonite I noticed they have a new kind of bakery dessert they're promoting. It's a flip-flop cookie.

You're supposed to pick up this day-glo green item that looks like some dirty open footwear that someone's skunky sweaty feet have been wearing, and stick it in your mouth and tell yourself you're enjoying eating such a thing.

Maybe it actually tastes pretty good, but it's a horrendous metaphor for something that's supposed to be edible(/palatable). What next, a dirty underwear cookie? With a cute little crotch stain made of fudge. How whimsically delicious!

p.s. And if you thought this JE was a waste of time, eat my shorts.

User Journal

Journal Journal: No wonder the Left foams at all orifices 164 164

Imagine winning three elections (one being a recall election that public sector unions poured thousands upon thousands of dollars into) in four years in the deeply divided blue-collar progressive Utopia of Wisconsin. Imagine breaking the back of the organized heart and soul of the Democrat party and dispatching AFL-CIO leader Richard "Morrie The Wig Salesman" Trumka back to the White House to show the President the "W" shaped scar carved into his forehead as a warning to anyone else who stepped foot in the state.

Imagine doing all this after Democratic state legislators fled for the safe harbor of Illinois to avoid voting on your legislation. Imagine having woken up every day to phone calls relating tales unionized shock-troops on your parentsâ(TM) front lawn and threats not only on your life but the lives of your kids. Now imagine having the real heroes, the brave national media, mock and ridicule you over this. Imagine accomplishing all of this while a partisan Milwaukee District Attorney authorizes the illegal invasion of the homes of your friends, supporters and aides, lawlessly confiscating private property, all while colluding with Lois Lerner and the IRS.

I happened to catch his announcement speech live on OANN yesterday. The Left will be invoking Cthulhu in most maniacal tones trying to call down some unfortunate demise on this Walker.

User Journal

Journal Journal: It just keeps getting WI-IRS 32 32

The two most egregious examples of government interference in recent elections may share a link. More than two years after it got exposed, the IRS' partisan probes of conservative groups applying for tax-exempt status remains unresolved, thanks to the obstruction of the IRS in producing the relevant records to Congressional investigators--and the refusal of Lois Lerner, the central figure in the scandal, to testify. The status of the John Doe probe in Wisconsin that also attempted to derail conservative groups from participating in elections is similarly unresolved, but has been halted by judges who may end up killing it and the law on which itâ(TM)s based altogether.

Stipulate that
- There Is Nothing To See Here, Move Along, and
- Nuremberg Defense, and
- Conservatives Are Just Lightweight Metallic Headwear Aficionados, and
- If The Tea Parties Hadn't Worn That Short Skirt To The Bar Where The Violent Illegal Alien Was Cleaning The Federal Agent's Hog-Leg, The Tea Party Probably Wouldn't Have Been Ventilated.
Those zany conservatives. Always going for the victim narrative.

User Journal

Journal Journal: Chronicle: Had a problem conceptualizing recusion in Java

I'm reading Java: A Beginner's Guide by Herbert Schildt. Schildt really is good. The lessons are smooth, with small complete examples of everything, explanations, and learning in steps, that is, each chapter builds on what was learned in the past. It's not just a bunch of concepts thrown together.. Here's one case where the O'reilly book just didn't do the job. It was good, but not for learning (reviewing, perhaps.)

I'm typing in every example, skipping the comments though. Also, changing names when they use plurals. An array should be named num, not nums, because each member is an instance of a num. It acts as a collections of nums, but it is not what it is. It's the J/P thing again. In databases, which is J territory, it should clearly be singular. Each record is an instance of the singular object (table.) And, people who think of tables in the plural often come up with terrible deigns and write horrible queries. Their using the database to support a specific process (which always changes, anyway) and not to hold data. They never learn. But i digress. Programs are about getting something done, so, it is more likely it should be named in the plural. I guess i'm in the wrong here. Though, as my code is for me (as opposed to if i was on a team), i'm going to follow my own preference.

In the Self Test for Chapter 6, question 6 is: Write a recursive method that displays the contents of a string backwards. I hit a mental block with that yesterday and just couldn't get it right. I was amazed (read: horrified) that such a small thing could be so hard. I ought to be able to (know what i need to do to) write that in seconds. After some fumbling over char vs String, it was time to go home. Today i approached the code and fixed it in just a few minutes.

class test06
{
  static String backward(String a)
  {
    if(a.length() == 1) return a;

    return a.substring(a.length() - 1) + backward(a.substring(0, a.length() - 1));
  }

  public static void main(String arg[])
  {
    System.out.println(backward("abcdef"));
  }
}

When i first got the question, i misunderstood it. I saw his answer and realized i misread it, so i tried this. Compared to his answer, he cheats. He used .charAt() to print out one char at a time from within the method. Granted, the book does that at this point, but this one is truer. And, i need something to be proud about.

But why did it take me so long? At first, i assumed its because i'm not used to Java, recursion is silly in this case, and i don't usually do recursion. But that's not true. I had a problem conceptualizing it, its effective, and i do it occasionally in SQL. But there's the answer. I do it in SQL.

Recursive CTEs are a pain. While more versatile than Oracle's hierarchical queries (which have a number of their own benefits), they are also confusing to learn. At some point it clicks though, and then its just a matter of keeping things straight in your head. However, in SQL's recursion the inner most level is also the final level. Outside of SQL, the opposite is true.

It's convenient to have blame it on SQL, though i know it's not true. Embarrassing as it is, i hit a mental block on the concept. Nonetheless, SQL likely had something to do with my confusion. I love these "easy" tests.

User Journal

Journal Journal: Well, this should be fun... 3 3

I went to SlashCode.com and saw there was a link for the code that runs Slashdot (well, probably several versions ago). Fine. I have a file called Bundle-Slash-2.5.2.tar.gz . There's a link for instructions, BUT it's a dead link.

I wonder how long it will take before I have something useful?

If I can get it running, I'll let you all know... Pudge, if you're reading this... A little guidance would be greatly appreciated. :)

User Journal

Journal Journal: Rant: Why i hate Java (simple, old debate) 4 4

Why do i hate Java? (And C too.) retardedNames, case sensitivity, offsets treated like indexes. These are examples of where programmers had good ideas but then unfortunately designed them into a language.

0 is not a number. A number represents a quantity and 0 is not a quantity. You don't declare an array less one because 0 is a number. However, it is treated as a number for convenience. Why then refer to an index in an array with 0 first? Okay, okay, i know. It's because the variable is just a pointer, and the index is really an offset. So then why use an offset to index an array? Seriously. In how many cases do you treat the offset as an index. And in how many do you treat it like an offset? I thought so.

Then there's the whole = vs ==. Debate over whether = should set or compare is understandable. Personally, i would never have used = to set, because most people use it to demonstrate equality. Not to test it, but to demonstrate it. As in any math equation we teach children. With that in mind, i would think it was more likely to be used to test equality rather than set it. Furthermore, pick the odd operator out: =, +=, -=, *=, /=. ^=. Yeah, yeah, those are for convenience. But how many times have you mistaken the double-character operator for anything else. Yes, but they have another operator that makes it obvious. Exactly. Isn't == obviously setting without an operation. x += y adds y to x then sets. x -= y subtracts y from x then sets. So, x == y should equal y to x then set. Slightly bumpy because it sets x to y and not vice versa, but its really easy to understand. And, earlier languages did it with :=. Same thing.

BASIC used = for both. Noone used LET outside of teaching. Regardless, context defined it anyway. Context is not available in Java because it allows you do do nifty things like increment an array offset while setting it. So, no context. Of course, this leads to bugs and the niftiness is often considered bad practice, but isn't it cool that we can do it?

I've seen absolute morons coding in BASIC. But never once had i seen them use = to do what they didn't intend. You know why? Because its impossible! Context rules. On the same note, i've read about talented programmers who made the mistake in C(++).

Prefix and postfix ++ and -- are a little different. They are not obvious (until you know what they do), and other than errors in logic, they are used as intended. They break context, per se, but that is what they are designed to do. Applying this to the poor = sign is just plain ridiculous.

Seriously, why are these things done when they are counterintuitive, prone to bugs, and bad practice? Were the designers brain dead, or just 31337 h4x0rz that hadn't grown up yet? Or, is everyone so blind to this because they never made this mistake.

Okay, the languages weren't designed inasmuch as they just ended up being used. But why? Was it because the pros outweighed the cons? Or was it because programmers actually like this nonsense?

"We don't care. We don't have to. We're the Phone Company."

Working...