Slashdot Mirror


User: bored

bored's activity in the archive.

Stories
0
Comments
1,324
First seen
Last seen
Profile
(view on slashdot.org)

Comments · 1,324

  1. Re:C: K&R. on Best Reference Site For Each Programming Language? · · Score: 1

    If your using a terminal to for actual programming, then you seriously need to reconsider your situation.

    Setup some kind of file sharing (file push over serial, whatever) and use a more modern machine for editing the code. Get yourself a nice programmers editor with syntax highlighting, variable completion, hinting, tags/cross reference, etc. Every programmers editor I've used for the past two decades had some kind of scripting capability which would allow you to script a remote update/compile sequence and bind it to a key. The savings in productivity will seriously outweigh the cost and initial configuration time.

    Once you have done that, and are sitting in front of a modern editor running over two or three monitors, your going to discover that styles created for 80x25 terminals are not optimum. Your going to discover that 5-25 character variable names massively increase readability and therefor maintainability, your going to discover a whole new world. The result will be a discovery that, its really hard to express anything in 80 columns after you have eaten up 16 columns for two 8 character tab stops, and each variable/function name takes up 1/4 of the total space available.

    I don't have any sympathy for people using a terminal now days. You can get junk PC's and high resolution CRT's out of the dumpster. If you can't figure out how to use those machines for text editing instead of a dumb terminal, even if your target is a 30 year old mainframe, you shouldn't be programming,

    When your done, we can have the conversation about why the K&R book had its syntax updated, but not its style. Many of the stylistic things in K&R directly result in _BUGS_ or hide them. That book is rife with examples which result in code which can be exploited for buffer overflows or dozens of similar problems. Basically, put K&R on the shelf and pull it down when you have a grammar question, but _DON'T_ write programs like the examples.

  2. Re:C, was (Re:Perl and Python) on Best Reference Site For Each Programming Language? · · Score: 1

    While K&R makes an excellent reference book, you must be very careful not to write programs like they are written in that book. The newer versions have been updated to be compliant with the C standards, but the programming style is firmly stuck in the 70's. This leads to code which is frankly unmaintainable. For example, pointers have their purpose, but they should be avoided except where they truly make sense. For example, pointers in a link list make sense. Using pointers to access array elements is just plain stupid. The code becomes hard to read (which array does p point to again?, how far into p are we?) and is generally harder to debug from a crash dump.

    The original excuse was *p was faster than p[index] is simply false with any modern compiler and machine.

  3. Re:Police State on Administration Claimed Immunity To 4th Amendment · · Score: 2, Interesting
    The insurgents would only need to gradually take control of their local geographies and prevent the oppressive government from exerting its influence over the area.

    There is the beauty in the theory of the US style of goverment, basically you don't need military force to take over the local geography. You can politically take over the local and state govements. Your local city can tell the state to f-off about education requirements, or a sufficiently strong state goverment can tell the feds to f-off, as quite a number of states have for the whole Real ID act. Another case was the http://en.wikipedia.org/wiki/National_Minimum_Drinking_Age_Act, but that eventually went through when Louisiana finally ended up caving in nearly a decade later. I expect the Real ID to go much the same way, a few states will hold out for a few years until they see its pointless.


    In theory though, its possible, the problem has been quite a number of supreme court decisions over the last 100 years that opened the door for the feds to have leverage over the states that simply should never have happened. In some cases the results have been positive (think EPA) but they damage the system in terrible ways. To do it right the EPA, social security, etc should have been constitutional admenments but there have never been sufficient political power to ram those through, and if there had been i'm sure a number of even uglier things might have gotten in too. In the end we need a new constituion every once in a while, but the result if someone were to write it today would be truely be a police state. It seems impossible for anyone to say, sure thats an ugly crime but trying to close all the loopholes will do more damage than allowing one or two people to get away with it. Instead we get knee jerk reactions to 9/11, sex offenders, drug users, etc because no one is willing to stand up and defend them or have more nuanced discusions about paricular cases. Instead we have these legislators who have unrealistic views of real situations stitting in ivory towers having BS views of the world, being pushed by a population that can't even descibe their system of goverment to a 3rd grade child.

  4. Re:worth a read on Scientists Create Room Temperature Superconductor · · Score: 1

    I don't buy that lowering taxes will cause more research. There are to many ways other affects depending on each companies competitive landscape. For example, the shareholders might just get larger divided checks, or the product the company produces will simply get cheaper in an attempt to buy marketshare. If the competitors also lowering their prices all you get is cheaper products. Finally there are other ways than bonuses for the exec's to take home the bacon, for example, maybe it would be nice if the company buys a newer/bigger jet.

  5. Re:My old benchmark on Benchmarking the Benchmarks · · Score: 1
    finding the size of the memory heap:

    void doit(int i) { printf("%i\n", i); doit(i + 1); }

    Oh god! What has become of this site? Poor spelling and grammar I can understand. Confusing the stack and the heap is a sign of the times!

  6. What a joke... on Time-Warner Considers Per-Gigabyte Service Fee, After iTunes · · Score: 1

    Its as bad as these colocation services that charge a flat fee plus a few dollars a gig.. Bandwith is stunningly cheap when you buy it in quanity. Even so, lets do a little thought experment. Lets say I have a 56k modem, and I can get 5k/sec. There are ~2592000 seconds in a month, so this means running full bore, I can download ~12G a month on a _MODEM_. The end result is people will start finding alternatives. Aka go to the local wireless cafe, if time warner does this I _WILL_ switch. I've been looking at alternatives since they started throttling upload speeds everytime they raised the download speed. I got better service from them 10 years ago, back when the max download speed was only 2mbit. Back then the upload speed was 1mbit, and my ports wern't being blocked.

  7. Two way media. on Fixing US Broadband Would Cost $100 Billion · · Score: 1

    As everyone knows, the internet is a two way media. This means that I need REAL broadband to send hidef movies of my kid to her grandmothers who live ~1k miles and ~7k miles away. I also need a fast upload speeds so that I can run rdesktop/X to my compile box at a speed that doesn't make me cringe everytime I need to make a quick edit before starting an hour long compile. While I have a 8mbit cable modem, the 384kbit uploads speeds are a joke. Right now I would be willing to pay 2x as much for 2x the upload speed, but its simply not avialable. Its like the cable and telco's are in collusion with the RIAA/MPAA to completely fsck the customer.



    I actually had faster speeds back in 1999 when I first got the cable modem, back then I was only getting about 2.5mbit down, but i was getting ~1mit up, since then at every speed bump making the modem "faster" the upload speeds have gotten slower. As far as I can tell this is completely artificial, the DOCSIS 2.0 spec says that its 38down/27up, and I can get 8Mbit down where is the missing ~5mit upload speeds? I can only guess that its sitting unused because time warner is hearing from warner brothers and warner music that they are loosing major $$$ to the cable customers sharing their movies. Plus, there is DOCSIS 3 which goes way over 100mbit, but I haven't heard of anyone with a cable modem getting that kind of speed, and its not like they couldn't bond a couple more channels together and make a DOCSIS 4.. The lack of "broadband" is completly artificial and a way to milk the customers for every penny while offering them the absolute crappiest service possible.



    Really the goverment needs to step in and get some goverment agency to set some high minimum standard (set to grow based on some formula of what speed the fastest 1/3 of the population can get). Any area which is less than the minimum standard, results in the goverment building out a network of fiber in that area within a year or two. The resulting fiber becomes part of the public infrastructure and is managed by nonprofit trusts. We will see how long the cable/telephone companies will sit on their a**'s when they see the goverment walking into a neighborhood wiring it up with fiber and giving people VOIP phones and gbit+ internet connections for some pittance. I will bet every cable customer will be at 100 mbits by the end of the year, and the phone companies will start offering 1/2 gbit connections to neighborhood fiber drops faster than you can wonder why your grass is being torn up.

  8. Re:Parents aren't early adopters on HD DVD Prices Slashed By Toshiba · · Score: 1

    Exactly, look for sony's response to a number of people complaining about blockbuster and netflix scratched bluray disks. Apparently their response is something like don't rent movies. The bluray coating is necessary because the information is right there on the surface instead of behind a thick layer of plastic. So basically, its slightly harder to scratch but if you do, your screwed.

  9. Cheaper than $149, and other comments. on HD DVD Prices Slashed By Toshiba · · Score: 1

    First its not just $149, which is how much best buy, fry's etc are charging. Tiger direct has them for $129 with 7 free movies. As others have said they should have done this last year.


    For HD all is not lost though, its possible that in walmart style stores they might sell a lot of them. The problem is that idiots at best buy, fry's etc will spout the same crap about technical superiority and how the war's already over that people on this board are spouting (which is shocking considering the DRM restrictions on bluray vs HD). In fact its the same crap they have been saying for the last year. In truth the image and sound quality of the two formats are basically identical (same codec's etc), the capacity limits on HD are BS since most of the blu-ray titles are on single layer 25G disks. In theory the java implementation on bluray is better, in fact it sort of sucks, reading the reviews on amazon of the bluray players gives you an idea of the problems people have with insanely slow load times, disk/player incompatibilities etc. Apparently the bluray technical committee voted against java, but the decision was overridden. Many of these problems are fixed with firmware updates, but many of the players don't have ethernet ports, and some don't even read CDR's (BDP-S300 for example) so you end up burning DVD-R's to do firmware updates. In the end, early adopters who bought standalone bluray players will need to buy new ones to get all the features the first gen HD DVD players already had. With profile 2.0 and the addition of M$'s and HDDVD's iHD format its likely many of the profile 1.1 players will only work in a degraded state if at all. Profile 2.0 could just as well be called HD DVD with extra DRM and an unused java engine maintained for backwards compatability.


    For the last year or so, anyone claiming bluray was better obviously hasn't tried one of the HD DVD players. The user experience between the two is night and day, the ~$139 Toshiba A3 against the ~$299 Sony BDP-S300 (profile 1.0) is astonishing, the A3 boots in a few seconds, loads disks in a few more, and massively responsive. The semi transparent menu's smoothly fade in over playing video content, the fast forward, rewind pause actions respond instantaneously. Its really stunning, plus for those people who like alternate PIP streams and buying movie junk over the internet HD DVD's just sort of work.


    Anyway, I'm all for the war. Real competition is good for everyone, I don't care if the $99 player is being subsidized (i'm not sure the subsity is that large, the HD technology isnt some super advanced stuff, compared to $50 upscaling DVD players) to gain market share. What I care about is that I can get a really nice HD player for $129 and HD movies for ~$10-$15. Even bluray fanboy's should be loving this war as they snatch up heavily discounted disks, and the price of bluray players falls 300% a year. My personal bias wishes that the war lasts another year or two in a stalemate, hopefully by that time the dual format players will be available for ~$150 and the single format players less than $100. This is the best route for the customer, if this doesn't happen don't expect the prices of HD dvd's to be less than $20, and the players won't fall in price for another 5 years or so.



  10. 4.8Gbit USB ~= 400MB/sec != 600MB/sec on USB 3 in 2008, 10 Times as Fast · · Score: 1

    Ok given a 4.8Gbit link the real transfer speed is probably about 480MB/sec after 8b/10b encoding, then given a 10-20% hit for the USB protocol, your probably talking about 400MB/sec, not the 600MB/sec other people are assuming.

  11. Re:Wrong on USB 3 in 2008, 10 Times as Fast · · Score: 1

    You forgot to subtract protocol and bit encoding overhead. In reality there is probably about 480MB/sec of bandwith on a 4.8Gbit link (see 8B/10B encoding) then you have to subtract protocol overhead which for USB probably will burn 10-20% of that. So the end result is probaby about 400MB/sec.

  12. Re:speed over fiber vs speed of electrons over cop on USB 3 in 2008, 10 Times as Fast · · Score: 1

    This is why you should buy a good switch (instead of a hub). Twisted pair is full duplex and a good switch will simply buffer anything sent from multiple sources at the same time. The carrier sense aspects of ethernet are basically dead, if the swtich buffer fills up for a particular destination it can throttle the source using the pause aspects of modern ethernet.

  13. Re:Not like it really matters . . . on FCC Says Analog TV Lives Until 2012 · · Score: 1

    Ha, I had "free" cable with 100+ channels, and I could never find anything to watch worth a damn on anything other than PBS and HBO. Then I moved from my apartment to my house and found out it would cost me $70 a month for PBS and HBO because I have to buy some stupid package before they let me get HBO, so I canceled the whole thing picked up a netflix account and an ATSC reciever. The local PBS station comes in over ATSC quite nicely thank you, and while netflix really sucks, now I get a few movies, and some HBO specials on DVD. Lately I've been thinking, why do I need the netflix hastle? Torrent is _SLOW_ but I can get a movie in a few hours vs five or six days with netflix. BTW: Back around the time I canned cable (I still have the cablemodem) I relized that part of the reason I rated HBO and PBS a head above some other channels like Discovery, TLC and history channel that I sometimes watched was because the idea of wasting 1/4 of the hour watching the same BS commercials, and then 1/4 of an hour listening to the stupid program repeat itself for people who missed the first half was simply a waste of my time. Even the "good" programs could often be condensed into a 15 minuite program if they played the thing straight through.

    The industry basically screwed itself in my case, the cost was to high in $ and time wasted, this didn't even count all the other BS the cable company pulls that pisses me off.

  14. Re:The digital TV switch isn't going to happen on FCC Says Analog TV Lives Until 2012 · · Score: 1
    The digital signal is designed to filter out this kind of thing, and so the ghosting disappears, giving a much sharper signal with digital.

    That is complete BS for the ATSC standard in the US, in fact its the complete opposite (random google hit) "Another serious problem with digital television is a reflection or ghost signal. A reflection signal can cause a digital signal not to display." http://abclocal.go.com/kfsn/story?section=ontv&id=4520006. Reflections are generally at the same frequency and incredibly difficult to remove in _ALL_ digital systems because traditional analog filtering does not work. BTW.. do you know what a terminator does?


  15. Re:Spotlighting no action on Richard Stallman Proclaims Don't Follow Linus Torvalds · · Score: 1
    I don't know those reasons, and don't expect them to be announced. But I can imagine the NVidia isn't entirely free to release code: for one thing, they might be paying royalties to others and be bound by those agreements. Or they may have tricks they think ATI/Intel doesn't know about. NVidia's managers have an obligation to safeguard shareholder's property.

    Which doesn't do one damn thing to explain what exactly is so secret about their motherboard chipsets which apparently are 99% the same as everyone else's. Yet those are super secret too, and we have network drivers and other nividia crap that only works through the hard work of people reverse engineering the damn things. People arn't asking for the trade secrets just the interface documents, your argument might hold some water for a graphics card but it doesn't hold any for the timing registers on a memory controller, or a basic ethernet controller.

  16. titanic models on John Knoll on CGI, Tron And 25 Years of Change · · Score: 1

    You of course realize that for titanic many of the ship scenes were giant sets, and models with CG backgrounds added afterwords? A quick web search picked this up http://titanic.pottsoft.com/home/titanic/film_set. html. I just remember seeing a documentary about the films special affects, and the absolutly huge models built while the CG was used to add enhancments to the film. Things like the scene with people sliding off the deck was done with a giant model and CG people added afterwords.

  17. Re:Don't fall into the trap on Microsoft To Dump 32-Bit After Vista · · Score: 1
    But pretty much any other ISA is better documented than x86.

    Having actually done a decent amount of programming on some other platforms, I find this funny. Usually with x86 there is just a big gap in the manual about some piece of behavior or another. With the other platforms there is usually a line that says "the behavior is undefined". Which is _SO_ much better.

  18. Re:I'll bite on Higher Pay for Math and Science Teachers · · Score: 1
    I totally disagree... To be successful in 99.9% of history classes you have to be good at two things. Memorizing and writing down what you've memorized. If you gave your average student a copy of their textbook and unlimited time to flip through the pages they would ace a typical history exam a 100% of the time.

    There is a point here, while I will agree that math and science courses make you more employable, I will disagree with the statement that history is pointless. The problem here is that its generally taught as a names/dates course even when the teacher says otherwise. See, history is really about politics, economics, military strategy, sociology and a bunch of other "soft subjects". Understanding the motivation and logic behind history is just as much about critical thinking skills as any math class. Its not until you get into game theory that you start to see weak mathematical relationships in human behavior. The preconditions around a particular historical event are often more important than the event. I loved history classes and hated math classes until I hit HS when the situation reversed and it became more about understanding math and less about what 123456*789790= and more about solving problems. At about the same time my history classes started being all about what year did such and such do whatever.

    So, there is a huge component in there about how well the subject is taught. Someone who doesn't understand the basics of the internal politics of the roman empire will never be able to teach history in a manner which is anything other than Julius Cesar was stabbed on march 15th. Consciously understanding human behavior both individually and in groups make you a much more valuable person in any situation that isn't a raw math problem. I work as a software engineer/programmer and in any project with more than a few people and a few hundred thousand lines of code the raw programming/computer problem solving is less than 50% of the work. The rest is "soft subjects" like being able to predict the future. The fact that history is dismissed by educated individuals says more about the holes in their education than anything else. See gulf war #2 and the idealism that got us into it. The US over the last 30 years is a case study in what happens when the people in your democracy don't know any history.



  19. Re:Hmmm...capitalism not all the rage in academia? on Higher Pay for Math and Science Teachers · · Score: 1

    Sucking them dry isn't accurate. I've seen figures that put the extra amount the health care and benefits cost the American auto manufactures at roughly $250 a car (in arguments why the unions are sucking the company dry no less). This is complete BS $250 isn't what is killing the company there are dozens of reasons that all point at poor management. For example a few years ago it took 30% longer to produce a similar car (foreign were in the 20 hour range and the Americans in the 30's). This is getting better its probably closer to 15% now that its been identified as a problem. Another problem is the general marketplace view of the automobiles produced. There wasn't a single American car/minivan/etc in Consumer reports best list for this year. The list goes on, the unions aren't stupid, when the parent companies are stronger they benefit more, so the unions are always conceding things. I can't remember the last time there was a strike because a plant was moving out of the country. Just because its fashionable in some circles to blame the unions for all the woes of the parent company doesn't make it true.

  20. The differences aren't as important as the support on Pthreads vs Win32 threads · · Score: 1

    I did win32 API coding at a previous job, at this one I use pthreads all the time.

    The real difference isn't so much in the basic thread library but what you can do once you have the thread. There are a LOT of gotchas with standard unix library calls in a threaded environment. When you start digging you discover all kinds of uglies when mixed with the API's that existed before pthreads. Things as simple as open/close are stunningly broken on many unix'es when mixed with threads. Far to many things in the basic API assume a single thread. When mixed with signals, async IO, DIO etc your world quickly starts to fall apart and you loose cross platform portability, and end up abstracting things away to just the functionality you need. At that point you might just as well use whatever native API's exist with object wrappers.

    Windows has its share of gotchas but the basic libraries work well with threads and provide everything you need without having to wonder how your going to get a thread safe version of getenv() (getenv_r() is not supported in glibc).

  21. Re:Divide and conquer on Beating Procrastination with Self-Imposed Deadlines · · Score: 1
    Um, I know where you're coming from, but this is exactly the opposite of what you should do. If you have a large project, you want to pick the most difficult, most risky portion and dig into that first. Why? Because if you need to scrap an idea, you need to know ASAP.

    Exactly, this isn't writing a term paper. I would add, once you get it working spend 1/3 as much time as it took you to get it working thinking about how to improve it. Usually this results in a lightbulb going off and the whole thing being rewritten in significatly fewer lines of code, with much better maintainablilty. If that doesn't happen usually the extra time will help work out edge case bugs and other improvments. By definition this is the most critical part of the system, you will want it to be as good as it can be.

  22. Re:bullshit on Bjarne Stroustrups and More Problems With Programming · · Score: 1

    The funny thing was that paper was written in 2005, if you look in Knuth's V1 first edition, and read his section on garbage collection you get basically the same information (GC's suck when memory gets tight, the result is that a GC needs a certain amount of extra space to keep performace up). That was known in the 1960's, doesn't appear that much has really changed.

  23. Re:sun and wind ( on Hydrogen Won't Save Our Economy · · Score: 1

    Ok, here is a full US wind map http://www.nrel.gov/wind/images/wherewind800.jpg there are more detailed ones, but notice the majority of the contental costline is =5.

  24. Re:sun and wind on Hydrogen Won't Save Our Economy · · Score: 1

    Maybe in your country, but there are a lot of places where the shore line isn't the some magic bullet for wind power. Especially when the shore itself is heavily urban. Then you have to build offshore which drives the construction costs up considerably. Where I live the sea breeze dies during the middle of the day or at night for good portions of the year. Other places are hurricane prone which also drives up the contruction costs.

  25. Re:sun and wind on Hydrogen Won't Save Our Economy · · Score: 1
    OK, so it is a weak energy source. I agree it is not on par with hydro, coal, or nuclear. Did I ever counter THAT?

    It is irrelevant to my point which is: energy is transportable, even on quite long distances, when converted to HV electric energy, which it usually is.


    I think there are few points here: first energy transmition losses are a function of distance. The greater the distance the greater the loss. The second is that most of the really good places to build wind generators are _FAR_ away, a lot farther away than your average electric plant to its customers. The third point is that wind is a marginal energy source. The combination of these three points make it difficult to justify. Especially when combined with the fact that it needs some form of backup generation for those days when the wind doesn't blow like you want it (even in the good places), or the load is particulary high. That is why wind generation is unlikely to be the final solution. Combined with other marginal technologies like solar make the problem is little better. In a capitalistic society its _VERY_ unlikely that energy producers are going to overbuild wind and solar techology enough to allow it to product 100% or really anything close to the energy requirements. These are the same people who cant even meet unexpected demand because they don't have enough backup generators and there can be day or two long lags spinning up what extra capacity there is. If the current model were applied to a solar/wind generation scheme your power would probably be off a lot more frequently.