News for hackers. Stuff that matters.

skip

Oh, I missed this detail. In that case for a deterministic result I think you need to look at every possible combination. However, you can order them by the minimum criterion first, and start searching from the smallest to largest, so then the first group than meets the interval criteria is guaranteed optimal.
Since the count of items is known a priori (=sizeof(S)), doesn't that mean that the mean and the sum are related in a well defined way? Basically then both critera can be simplified to a single criterion on either sum or mean.
Yeah, I would. If you have a laptop just set the max CPU speed to 80% (or whatever, <100%) under power options to simulate the pain.

Maybe if you just type emails and surf all day it's not an issue, but if you are debugging big applications, it is most definitely an issue.

Re:Sleep Deprivation May Spur Serious Mental Problems, Study Finds on Thursday September 02, 2010 @09:12AM (#1656032)
Well, I came in here to say exactly that: the paper is based on a survey of people self-reporting their past history with sleeping. Not a very good way to control the results.
Like any other development tool, you can leave the smartphone on your desk. No need to carry it around.
Unless you are saving lives (a doctor) or protecting the country (in defense), or maybe a few other edge cases, the perception that you need to get back to a person in a few hours is probably more on your end than on the recipient's.
Re:Ask HN: What motivates users to write Amazon reviews? on Thursday June 24, 2010 @12:55PM (#1458471)
Amazon and Newegg both email me after I make a purchase requesting that I review the product. They do this a little after the product is delivered--to give me a chance to use it.

I almost always respond to these requests, because I find the reviews helpful in my buying process and that motivates me to contribute back.

Re:Microsoft launches "Fix It" on Monday April 19, 2010 @08:53AM (#1276570)
This has been a part of the MS knowledge base for at least one year. Why is this "news" now?

http://blogs.technet.com/fixit4me/archive/2008/11/19/welcome...

Re:Ask HN: Who's hiring? on Wednesday March 24, 2010 @12:05PM (#1216024)
[Boston, MA] Delsys, Inc is hiring Win32 desktop application developers. http://jobs.stackoverflow.com/default.asp?6580
The content (search results) mimic too closely the ad results.

Using whitespace to separate them (or a thin blue line, like the google sidebar ads) may help. Icons would brighten the design too.

It's difficult to scan the list and look at prices because they are not aligned.

I would suggest and icon in a column on the left, with the stars (rating) and price below it, then the name, description, and links on the right.

This is actually not a bad idea. I've graduated now, but I would always start taking notes on each reference at the end of my paper. So it's definitely fulfilling a need.

But I wish there was a lower threshold of participation--couldn't I sign up for an anonymous account, and then attach my name to it once I decide that it's useful for me?

Also, Inkscape and GIMP are free, and just as powerful as the Adobe suite, especially for making more basic stuff like icons or logos. Perhaps if you are into photo manipulation or use Fireworks for web design there is some benefit to getting the Adobe stuff.

Coding for GPGPU or stream processors
Re:Shor, I’ll do it on Thursday December 10, 2009 @11:10AM (#988032)
Unfortunately he did not credit Feynman for the 'clock' analogy, who I believe originated this way of describing quantum processes.
Re:Twitter as a forensic tool on Saturday October 10, 2009 @11:44AM (#873416)
Wow, this article is particularly vacuous. Someone died, and someone twittered. Lets draw conclusions!
Re:BadaBingle = BingGoogle² on Wednesday August 26, 2009 @04:31PM (#788001)
Yawn. I might as well have two browser windows open. This should ferret out duplicates and merge the two sets of results. Like a metasearch engine.
Works in Chrome 2.0 on Vista.
Re:The One Character Block Comment on Tuesday July 21, 2009 @11:19AM (#716366)
It's a nice trick, but I will probably stick to Ctrl-K-C (block comment) and Ctrl-K-U (block uncomment) in Visual Studio, just out of habit. I hate leaving big block comments in the middle of a module anyways: hurts readability.
Chrome has a nice feature where you can drag a file from any folder/your desktop and drop it onto a file input element on a web page.

Unfortunately, this feature does not work in Gmail (!) because they use a custom Flash-based uploader there.

This is in no way better than regular pagination. Or, if you want to eliminate a full page reload, just do the pagination in AJAX (but still allow me to link to a specific page).

Pagination does not break the back button or the scrollbar like progressive loading.

Re:Scribd Streamlines Embedded Docs With iPaper 2 on Friday July 10, 2009 @07:51PM (#698622)
Can't agree more. And they want me to sign up in order to see or download a plain PDF, thats not going to happen.
Re:Brainfuck compiler in brainfuck on Friday July 10, 2009 @08:05AM (#697512)
Source code contains (slightly NSFW) ASCII art--that's awesome.

http://code.google.com/p/awib/source/browse/builds/awib-1.0r...

Re:The Firefox 3.5 fiasco on Thursday July 09, 2009 @05:55PM (#696698)
And this is precisely why the most recent Firefox install I have is from the 2.x series. It used to be that Firefox (then Firebird) was the lean and mean cousin of bloated Netscape. Alas, age has taken it's toll and the amount of built in crud in Firefox that has nothing to do with downloading had display HTML documents is overwhelming...
Re:IPhone-like password fields on Thursday July 09, 2009 @01:36PM (#696312)
Well from a technical standpoint you are correct. Although, if I see buggy/weird behavior on a website, right away I question what sort of hidden unsavory stuff is happening on the server side.

But there is an issue even if the implementation is totally seamless and bug-free. Maybe one site implements this slightly differently, and maybe some sites have a checkbox to clear the mask, or other sites show me each character for a fixed delay (e.g., character disappears after 250 ms or something), etc. In each case I must make some accomodations to how I expect a password field to behave. On the other hand if it is at the application level then there is opportunity to evolve the feature uniformly across all websites--and also give the user a single option which controls the behavior.

Re:IPhone-like password fields on Thursday July 09, 2009 @10:29AM (#695923)
The reference implementation seems very buggy--moving my caret and having inconsistent behavior.

I would certainly be hesitant to type my password on a website which is handling the field like that. Let the browser vendors implement this option at the application level (as an option, probably, so users can enable/disable on all websites).