Oct. 20th, 2009

elfs: (Default)

Do you have that one thing that you have to constantly look up?

In python, to replace elements of a string, there are two operators.  One is a strictly linear search, the other uses regular expressions.  The regexp call to replace part of a string with another string is sub, and the string call to replace a part of a string with another string is replace.

I get these backward all the flamin’ time, and it drives me insane.  I use both of these every day, why the Hell can’t I remember which is which?

This entry was automatically cross-posted from Elf's technical journal, ElfSternberg.com
elfs: (Default)
We know soldiering– I mean not training or support or peacekeeping or any of the myriad other things soldiers do, but facing enemy bullets– is inextricably bound up with ideas of masculinity. We also know that most heterosexual males' ideas of masculinity are inextricably bound up with what we now call sexual orientation. In other words, "being a man" typically does mean for soldiers both being brave, stoic, etc.– and being heterosexual. Another way to put this is to say that honor, which is by the testimony of soldiers throughout the ages of the essence of military service, includes the honor of being known for heterosexuality, and that, for most heterosexual males, shame attends a reputation as much for homosexuality as for weakness or cowardice.
Whole thing here.

Profile

elfs: (Default)
Elf Sternberg

June 2025

S M T W T F S
1234567
891011121314
15161718192021
22232425262728
2930     

Most Popular Tags

Style Credit

Expand Cut Tags

No cut tags
Page generated Jul. 17th, 2025 04:08 pm
Powered by Dreamwidth Studios