You've apparently forgotten about Permutation Sort (generate all permutations of the array; the optimized version allows you to stop when you find one that's sorted). It's O(N*N!).
Then there's Miracle Sort. Check whether the array is already sorted. If it is, you're done. If not, wait a while, pray for cosmic rays, and check again.
Back in college (UCSD, graduated in 1981) I programmed in UCSD Pascal on Terak 8510 microcomputers. LSI-11 based, 56K RAM, 320x240 monochrome bitmapped display, 8-inch floppy drives. They were pretty cool for the time; even with everything running under the P-code interpreter, they didn't feel slow.
By writing a 16-bit address into a specific register and twiddling a few bits in another, you could cause any specified 9600-byte chunk of memory to be continuously displayed on the monitor, updated 60 times per second. You could see dark vertical stripes every 8 columns if the displayed data happens to be ASCII text.
The Pascal compiler used this to show the top of the stack and heap (which grew towards each other). If your program was too big to compile, you could actually watch the impending stack overflow as the two areas of furious activity got closer to each other; finally they'd collide and explode into an error message.
I once wrote a program that mapped an array to the screen, filled it with random numbers, and ran Quicksort on it. You could actually see the recursion. I did the same thing with bubblesort; you could watch the region of activity move down the screen repeatedly. I never tried Shell Sort.
Nader should drop out of the race and endorse Kerry as the best and only way to defeat George W. Bush.
Then he should work to reform the electoral system so that a vote for a third-party candidate isn't effectively a vote for whichever of the two major candidates you like least. Preferential voting would allow a Nader supporter to vote for Nader, but specify that he'd still prefer Kerry to Bush.
If Nader stays in the race, and Bush wins by a margin smaller than the number of votes Nader received, Ralph Nader's legacy will be that he helped put George W. Bush in the White House twice; everything else he's ever done will be forgotten. Unfortunately, I think his ego has grown too big to let him admit that to himself.
If Nader doesn't drop out, I wonder if Pat Buchanan would be interested in running again. 8-)}
Penguin says that Katie Jones never trademarked "katie.com". Is it too late for her to do so now? If not, how much would it cost? (With all the publicity, I suspect the fees wouldn't be a problem.)
I don't feel sorry for this little whore! Not one bit! And neither should you.
That is entirely uncalled for.
Katie T, as far as we know, is not responsible for the "katie.com" brouhaha. As for what happened to her when she was 13 (or whatever age she was), I don't think either of knows enough about it to judge her. There might be some debate about whether she's a victim, but calling her a "little whore" is beyond the pale.
This kind of thing happens far too often on Slashdot. Someone is mentioned indirectly in a story, and people with no lives of their own feel free to start flinging misogynist abuse.
My guess is she's probably sipping mint julips under the cottonwoods enjoying here $$$$ from the book and doesn't give a rats ass about being part of a legal predator's actions.
At least you labeled it as a guess. It is, of course, nothing more than that. In the absence of any reason to assume that Katie Tarbox has acted maliciously, such comments are, to say the least, less than constructive. (They are, to say the most, potentially libelous, but IANAL.)
I've sometimes had problems with my keyless entry system (no idea what frequency it uses) in the parking lot at San Diego International Airport. I had assumed it was interference from the airport's radar, but there are several military bases in the immediate vicinity.
I voted on a Diebold machine in San Diego this month, just so I could see how the system works. The user interface was actually very nice, but I don't trust the system or the company that makes it. I intend to use an absentee ballot from now on, until and unless we switch to human-readable paper ballots. I'll fill out my absentee ballot and drop it off at my local polling place on election day. I may not be particularly quiet about it.
Using an absentee ballot will make it possible to recount my vote if necessary, but that doesn't do much good if everybody else's votes are miscounted.
Don't be fooled by talk of "paper receipts". What we need are paper ballots. If they're machine-generated, that's fine; it avoids problems with incorrectly marked ballots. If they're machine-readable, that's fine too -- as long as they're also human-readable.
A guy has an unusual car, it gets mentioned on Slashdot, and a few people use it as an excuse to publicly insult his wife (who happens to be a lovely person, not that it would make any difference if she weren't).
The point is that time() still returns a 32-bit value in both C and C++. That's the problem we're trying to solve here.
No, time() returns a time_t value. The C standard defines time_t as an arithmetic type capable of representing times; there's nothing in the standard that says it has to be 32 bits, or that it counts seconds from 1970-01-01, or even that it counts seconds. (I think POSIX imposes some more specific requirements, but it still allows a 64-bit type.)
I've worked on several systems that already use a 64-bit type for time_t. I suspect that all systems will do so well before 2038.
If the problem hasn't taken care of itself in 20 or 30 years, then we can start worrying about it.
(Switching to an unsigned 32-bit type would buy us another 68 years, but it would make it impossible to represent dates before 1970.)
First of all, anyone with a non-shitty browser can configure it to redirect the standard error to a custom error page - one more useful then "error: you suck" that most browsers do by default.
Really? I've used several different browsers, and I don't remember seeing this kind of configuration option. It would certainly be possible, and perhaps even useful; I just don't remember ever seeing it. Can you provide details for one or more of the more popular browsers?
the ACLU were the ones fighting for Diebold and for the death of paper voting.
and you who bitched about punch cards... feel pretty smart now, do you? at least with punch cards, the only thing stopping you was the moron voter.... now, we have the moron system running things.
The problem isn't just "moron voters". Punch card systems can have misalignment and jamming problems (if the compartment behind the ballot fills up, it can be difficult to punch out the chads completely). You can examine the punch card to see if the holes were punched out completely, but it's very difficult to tell whether you got the right ones -- and I must admit that I didn't bother checking before 2000.
My county is switching from punch cards to touch screens, and I'm not looking forward to it -- but electronic (or rather electronic-assisted) voting systems can be done right.
Not only that, but we have a tremendous number of distinct ballots. The various districts (Congress, state legislature (two houses), county board of supervisors, city council, and several others) overlap arbitrarily, so neighboring precincts are likely to have different sets of races.
(Our October 7 election here in California is an exception; it's the same statewide -- except for the order of the candidates.)
A number of CA counties use the touch screen machines, but the big holes are on the servers, not the voting machines. Those who use OCR ballots are also just as vulnerable because the back-end servers are the same.
OCR ballots can be recounted manually if necessary.
So is it toll free when you can internationally too? That would be cool.
I think it's toll free only from within area covered by NANPA (North American Numbering Plan Administration). I think there's a special area code that lets you call an 800 number from outside North America and pay a toll, and corresponding codes for 888, 877, etc.; I don't remember what they are.
As I learned it, a byte is the smallest directly addressable unit of memory.
The PDP-10 supported variable byte sizes, anywhere from 1 to 36 bits. The Jargon File says that the term goes back to 1956.
8-bit bytes are almost, but not quite, universal today.
In the context of the C programming language standard, a byte is by definition the number of bits in a character; it must be at least 8 bits, but can be more.
An interesting sidenote to this, 'bug' was actually in usage before the bug was found; it was an acronym for Byte Under Guard, used when an if/then block failed to test the byte properly.
The term "bug" was in use long before 1945, but the term "byte" only goes back to 1959 (according to www.m-w.com). The acronym for "Byte Under Guard" sounds like a back-formation.
Also, according to The Jargon File, the log entry with the moth is from September 9, 1947, not 1945. See here.
You've apparently forgotten about Permutation Sort (generate all permutations of the array; the optimized version allows you to stop when you find one that's sorted). It's O(N*N!).
Then there's Miracle Sort. Check whether the array is already sorted. If it is, you're done. If not, wait a while, pray for cosmic rays, and check again.
Back in college (UCSD, graduated in 1981) I programmed in UCSD Pascal on Terak 8510 microcomputers. LSI-11 based, 56K RAM, 320x240 monochrome bitmapped display, 8-inch floppy drives. They were pretty cool for the time; even with everything running under the P-code interpreter, they didn't feel slow.
By writing a 16-bit address into a specific register and twiddling a few bits in another, you could cause any specified 9600-byte chunk of memory to be continuously displayed on the monitor, updated 60 times per second. You could see dark vertical stripes every 8 columns if the displayed data happens to be ASCII text.
The Pascal compiler used this to show the top of the stack and heap (which grew towards each other). If your program was too big to compile, you could actually watch the impending stack overflow as the two areas of furious activity got closer to each other; finally they'd collide and explode into an error message.
I once wrote a program that mapped an array to the screen, filled it with random numbers, and ran Quicksort on it. You could actually see the recursion. I did the same thing with bubblesort; you could watch the region of activity move down the screen repeatedly. I never tried Shell Sort.
Ah, those were the days.
Rocks provides an easy way to build a Beowulf cluster. See http://www.rocksclusters.org/.
. shtml?tid=29&tid=94 for one account.
You can build a working cluster, starting with the hardware and installation CD-ROMs, in minutes; see http://servers.linux.com/servers/04/08/27/1943227
Disclaimer: I work with the folks who created Rocks.
You might take a look at Rocks:
http://www.rocksclusters.org/.
Quite a few people have built Rocks clusters out of a bunch of old computers.
Disclaimer: I work with the folks who created this.
Nader should drop out of the race and endorse Kerry as the best and only way to defeat George W. Bush.
Then he should work to reform the electoral system so that a vote for a third-party candidate isn't effectively a vote for whichever of the two major candidates you like least. Preferential voting would allow a Nader supporter to vote for Nader, but specify that he'd still prefer Kerry to Bush.
If Nader stays in the race, and Bush wins by a margin smaller than the number of votes Nader received, Ralph Nader's legacy will be that he helped put George W. Bush in the White House twice; everything else he's ever done will be forgotten. Unfortunately, I think his ego has grown too big to let him admit that to himself.
If Nader doesn't drop out, I wonder if Pat Buchanan would be interested in running again. 8-)}
Penguin says that Katie Jones never trademarked "katie.com". Is it too late for her to do so now? If not, how much would it cost? (With all the publicity, I suspect the fees wouldn't be a problem.)
I don't feel sorry for this little whore! Not one bit! And neither should you.
That is entirely uncalled for.
Katie T, as far as we know, is not responsible for the "katie.com" brouhaha. As for what happened to her when she was 13 (or whatever age she was), I don't think either of knows enough about it to judge her. There might be some debate about whether she's a victim, but calling her a "little whore" is beyond the pale.
This kind of thing happens far too often on Slashdot. Someone is mentioned indirectly in a story, and people with no lives of their own feel free to start flinging misogynist abuse.
My guess is she's probably sipping mint julips under the cottonwoods enjoying here $$$$ from the book and doesn't give a rats ass about being part of a legal predator's actions.
At least you labeled it as a guess. It is, of course, nothing more than that. In the absence of any reason to assume that Katie Tarbox has acted maliciously, such comments are, to say the least, less than constructive. (They are, to say the most, potentially libelous, but IANAL.)
I've sometimes had problems with my keyless entry system (no idea what frequency it uses) in the parking lot at San Diego International Airport. I had assumed it was interference from the airport's radar, but there are several military bases in the immediate vicinity.
For the record, I had nothing to do with this.
I voted on a Diebold machine in San Diego this month, just so I could see how the system works. The user interface was actually very nice, but I don't trust the system or the company that makes it. I intend to use an absentee ballot from now on, until and unless we switch to human-readable paper ballots. I'll fill out my absentee ballot and drop it off at my local polling place on election day. I may not be particularly quiet about it.
Using an absentee ballot will make it possible to recount my vote if necessary, but that doesn't do much good if everybody else's votes are miscounted.
Don't be fooled by talk of "paper receipts". What we need are paper ballots. If they're machine-generated, that's fine; it avoids problems with incorrectly marked ballots. If they're machine-readable, that's fine too -- as long as they're also human-readable.
"Honestly I don't care what her personality is, she's dog ugly."
Does it even occur to you that she's a real person, one who might very well end up reading your comments?
I presume that if you actually met her, you'd keep any such remarks to yourself. But I guess it's ok if you're hiding behind a keyboard.
This is funny?
A guy has an unusual car, it gets mentioned on Slashdot, and a few people use it as an excuse to publicly insult his wife (who happens to be a lovely person, not that it would make any difference if she weren't).
Ha ha, yuk yuk.
% perl 2038.pl
Tue Jan 19 03:14:01 2038
Tue Jan 19 03:14:02 2038
Tue Jan 19 03:14:03 2038
Tue Jan 19 03:14:04 2038
Tue Jan 19 03:14:05 2038
Tue Jan 19 03:14:06 2038
Tue Jan 19 03:14:07 2038
Tue Jan 19 03:14:08 2038
Tue Jan 19 03:14:09 2038
Tue Jan 19 03:14:10 2038
% uname -rsm
Linux 2.4.19-SMP ia64
% perl -e 'print scalar gmtime 1e16, "\n"'
Sat Jan 25 17:46:40 316889355
So what's the problem again? 8-)}
The point is that time() still returns a 32-bit value in both C and C++. That's the problem we're trying to solve here.
No, time() returns a time_t value. The C standard defines time_t as an arithmetic type capable of representing times; there's nothing in the standard that says it has to be 32 bits, or that it counts seconds from 1970-01-01, or even that it counts seconds. (I think POSIX imposes some more specific requirements, but it still allows a 64-bit type.)
I've worked on several systems that already use a 64-bit type for time_t. I suspect that all systems will do so well before 2038.
If the problem hasn't taken care of itself in 20 or 30 years, then we can start worrying about it.
(Switching to an unsigned 32-bit type would buy us another 68 years, but it would make it impossible to represent dates before 1970.)
I have a red sign on my door. It says "If this sign is blue, you're going too fast."
You want to freak people out? Replace it with a blue sign that says the same thing.
First of all, anyone with a non-shitty browser can configure it to redirect the standard error to a custom error page - one more useful then "error: you suck" that most browsers do by default.
Really? I've used several different browsers, and I don't remember seeing this kind of configuration option. It would certainly be possible, and perhaps even useful; I just don't remember ever seeing it. Can you provide details for one or more of the more popular browsers?
the ACLU were the ones fighting for Diebold and for the death of paper voting.
and you who bitched about punch cards... feel pretty smart now, do you? at least with punch cards, the only thing stopping you was the moron voter.... now, we have the moron system running things.
The problem isn't just "moron voters". Punch card systems can have misalignment and jamming problems (if the compartment behind the ballot fills up, it can be difficult to punch out the chads completely). You can examine the punch card to see if the holes were punched out completely, but it's very difficult to tell whether you got the right ones -- and I must admit that I didn't bother checking before 2000.
My county is switching from punch cards to touch screens, and I'm not looking forward to it -- but electronic (or rather electronic-assisted) voting systems can be done right.
How cool would it be...you screw up in govt, within 30 minutes you get your marching papers and the 'wildcard' entry gets a go.
Speaking as a Californian, it's not very cool at all.
One problem is the number of races on one ballot.
Not only that, but we have a tremendous number of distinct ballots. The various districts (Congress, state legislature (two houses), county board of supervisors, city council, and several others) overlap arbitrarily, so neighboring precincts are likely to have different sets of races.
(Our October 7 election here in California is an exception; it's the same statewide -- except for the order of the candidates.)
A number of CA counties use the touch screen machines, but the big holes are on the servers, not the voting machines. Those who use OCR ballots are also just as vulnerable because the back-end servers are the same.
OCR ballots can be recounted manually if necessary.
So is it toll free when you can internationally too? That would be cool.
I think it's toll free only from within area covered by NANPA (North American Numbering Plan Administration). I think there's a special area code that lets you call an 800 number from outside North America and pay a toll, and corresponding codes for 888, 877, etc.; I don't remember what they are.
As I learned it, a byte is the smallest directly addressable unit of memory.
The PDP-10 supported variable byte sizes, anywhere from 1 to 36 bits. The Jargon File says that the term goes back to 1956.
8-bit bytes are almost, but not quite, universal today.
In the context of the C programming language standard, a byte is by definition the number of bits in a character; it must be at least 8 bits, but can be more.
The log entry with the moth is from September 9, 1947, not 1945.
An interesting sidenote to this, 'bug' was actually in usage before the bug was found; it was an acronym for Byte Under Guard, used when an if/then block failed to test the byte properly.
The term "bug" was in use long before 1945, but the term "byte" only goes back to 1959 (according to www.m-w.com). The acronym for "Byte Under Guard" sounds like a back-formation.
Also, according to The Jargon File, the log entry with the moth is from September 9, 1947, not 1945. See here.