Better HN
topnewbestaskshowjobs
Log inSign up

ijoshua

82 karma · joined Sep 6, 2007 (19y ago) · 29 submissions

Submissions

comment 18y ago · link · parent

> Where can you point me to "better documentation than PHP"? This is a major difficulty for new people getting into Python-- the documentation is really quite poor and out-dated.

I disagree that the Python documentation is poor or out-dated. However, it is fragmented in what could be considered a confusing manner. I’ve often been searching for a particular piece of documentation, wondering if I should be looking in the tutorial, the library reference, or the language reference.

comment 18y ago · link · parent

Python‘s way of accomplishing this is as easy, although the use of `locals` should indicate that this isn’t generally something you should be doing:

    post = {'name': 'ijoshua', 'email': 'spam@example.com', 'extra': 'data'}
    
    filter = ['name', 'email']
    
    for k in filter: locals()[k] = post[k]
    
    print name, email

comment 18y ago · link · parent

I don’t know the details of the compiler, but the negation operator on int objects also has a corresponding method: `__neg__`

-1 == (1).__neg__()

comment 18y ago · link · parent

Principia Discordia; or How I Found Goddess and What I Did to Her When I Found Her

comment 18y ago · link · parent

See those arrows? That’s human moderation. Just don’t click on the up arrow if you think it’s spam.

comment 18y ago · link · parent

The privacy implications and “unintended consequences” of participating in Facebook are shocking.

comment 18y ago · link · parent

It was an apostrophe, but since Arc doesnaEURXt support Unicode, fuck it.

comment 18y ago · link · parent

The patent appears to predate PLTaEURXs work.

comment 18y ago · link · parent

How did you arrive at these conclusions? Did you use some programmatic analysis of CL source code to report these stats? Which codebases were your reference?

comment 18y ago · link · parent

mzscheme (PLT)

http://news.ycombinator.com/item?id=11994

comment 18y ago · link · parent

I looked at it very briefly. The codebase is actually pretty small. It appears to depend heavily on memcached.

comment 18y ago · link · parent

Whatever language, I just hope it comes with decent documentation.

comment 18y ago · link · parent

Given Lisp, I can implement a Lisp interpreter easily:

    (loop (print (eval (read)))

comment 18y ago · link · parent

If you give someone Fortran, he has Fortran. If you give someone Lisp, he has any language he pleases.

comment 18y ago · link · parent

Here-say and speculation, although not that far fetched.

comment 18y ago · link · parent

"Honour thy error as a hidden intention" - Brian Eno's Oblique Strategies

comment 18y ago · link · parent

I'd like to see a scoring system that evaluates the discussion or thread as a whole, rather than the individual contributions; a metric like a signal-to-noise ratio, where a thread gets a higher score for being on-topic and relevant, or a lower score for degenerating into a pissing match.

comment 18y ago · link · parent

<q>You just participated.</q>

I did not realize this was an argument. I guess I lost.

Seriously, though, the most interesting arguments don't resolve for quite some time, if ever. For example, who was the winner in the infamous Torvalds v. Tanenbaum argument over monolithic versus micro-kernels? One could say that Torvalds "won," in the sense that Linux became far more successful than Minix. Yet, Windows and Mac OS are both based, in part, on a micro-kernel architecture, and both have a greater share of the market than Linux.

comment 19y ago · link · parent

Easy. The losers are usually the ones who participate.

comment 19y ago · link · parent

Are you referring to the "JavaScript API" or the "Data APIs?" Because the Data APIs are pretty plainly based on the Atom Publishing protocol, with only a few extensions. Yes, many of Google's APIs are now based on Atompub, but that isn't something that Google invented from whole cloth.

comment 19y ago · link · parent

Google doesn't have to keep your data for you. The OpenSocial API is just a specification. Google's own applications implement the specification, and you can too. The API is designed to be able to work with data on any host. It's in the very nature of the addressability of the API's data. Look in the documentation, and you'll see lots of URIs that look like:

http://{domain}/feeds/people/{user-id}

Notice that "domain" is a variable. In any case, why would you worry about Google being able to store data that is publicly accessible through a standardized API?

comment 19y ago · link · parent

"But I think they're inherently slower for things like reporting."

I wouldn't say the deficiency is _inherent_, but the powerful indexing ability of a relational DB that we take for granted seems to be necessarily _ad hoc_ in an object-oriented DB. From my understanding, the index in an OODB is just another object in the database, which may be a B-tree, a hash table, or a simple sequential list. So far, that's fairly similar to the RDB. However, the indices in the RDB are closely coupled to the table that stores the records. The RDB "knows" that it should update the index when the table is modified. On the other hand, there isn't a table of records in the OODB, so there isn't a close coupling of the index to the data store. It may be entirely up to the application to manage the integrity of the index.

comment 19y ago · link · parent

PG, I'd be interested to know why you chose to implement a voting/rating system for stories on news.yc. That is, did you consider a "weightless" submission system like, for example, MetaFilter, where front-page postings are a privilege that every member has equally. I've been a member of MeFi for several years and the effect of "gaming" has never really been an issue there, because there is no reification of trustworthiness in the form of a "karma" score. Certain members there certainly have name-recognition based on their history, but this gains them nothing in terms of influence on the focus or direction of the site as a whole.

comment 19y ago · link · parent

"Most people aren't smart at all."

Very correct. In fact, nearly half of all the people you'll meet have a "below average" intelligence.

comment 19y ago · link · parent

"Maybe" is one option too many

http://www.zeldman.com/2007/06/20/remove-maybe-from-invitati...

comment 19y ago · link · parent

I would like it better if the "Comments" box didn't obscure the content. Even on my 1680 by 1050 monitor, with the browser window scaled to full width, I cannot move the comments completely out of the way. If the main content area was aligned to the left side of the page, rather than having equal horizontal margins, I could easily fit the comments into the margin.

[Edit: it seems that I cannot type Unicode characters into a comment here...]

comment 19y ago · link · parent

Oh noes! Write your congressperson!

28.

Password Security: A Case History(wolfram.schneider.org ↗)

1 points · by ijoshua · 19y ago · discuss

comment 19y ago · link · parent

As stated in the last few paragraphs, the simplest way to guard against this sort of attack is to salt the data before hashing it. What he doesn't discuss is how to choose a salt value. In a good hash function, every bit should affect the output, so really only a couple of bytes are needed for a good salt. Additionally, the salt value can be random and may include unprintable ASCII characters. Furthermore, a new salt can be created for every password. Now, if two users have the same password, the ciphertext will be different for each.

I've used this technique to store sensitive personal data which must be recoverable (i.e. credit card numbers.) When a new number is obtained, a few bytes of salt are randomly generated. The data, plus the salt, are passed to a symetric cipher, and the ciphertext and salt are stored in a database.

[edit: there's some discussion of this in the article comments.]