|
Haskellers seem to manage.
|
# ? Dec 11, 2015 15:01 |
|
|
# ? Jun 10, 2024 04:17 |
Make all the text boxes visible so he can recreate the Matrix
|
|
# ? Dec 11, 2015 15:05 |
|
qntm posted:Haskellers seem to manage. Bindings are just immutable variables
|
# ? Dec 11, 2015 15:11 |
|
hackbunny posted:Using the _ line continuation you mean? Yep. You can only get 3 lines into a method signature that way, so if you're writing abominations you'll still end up with hella long lines.
|
# ? Dec 11, 2015 16:44 |
|
invision posted:Overheard at work today: Oh hey, I did that in Visual Basic when I was like 5. It's a lot easier to grasp manipulating data with GUI elements when everything related to it is nicely laid out in the IDE, and you don't understand what classes or members are.
|
# ? Dec 11, 2015 17:42 |
|
HardDisk posted:Just how do you program without using variables? From what I imagine, he's been doing it the same way as you'd create mockups in uxpin - user clicks here, show this container, etc.
|
# ? Dec 11, 2015 17:51 |
|
It could be worse; he said he'd just discovered variables and it was a pleasant surprise. He might have reacted with "bah, I have a system that works fine already". That's a worse kind of situation entirely.
|
# ? Dec 11, 2015 17:56 |
|
Bognar posted:
I got that beat. Try debugging code where merely accessing a property causes other properties to mutate. After an hour of banging my head on the wall I found it. C# code:
|
# ? Dec 11, 2015 18:16 |
|
Brings Kirk to mind for some reason.
|
# ? Dec 11, 2015 18:23 |
|
HardDisk posted:Just how do you program without using variables? Very carefully
|
# ? Dec 11, 2015 21:18 |
|
Memory allocation is a side effect.
|
# ? Dec 11, 2015 21:45 |
|
We have Delphi forms at work that have "query" components splattered all over them because since those are available as a drag+drop component, it's apparently bad form to query the db without having one or thirty clearly visible in the form designer. Like, we're all aware of variables but I guess we don't really trust them to hold objects.
|
# ? Dec 11, 2015 22:19 |
|
Joy, my co-worker submitted a pull request that includes a "SemaphoreService." This doesn't sound goodcode:
Edit: We don't even need these stupid locks - we could get rid of this entire service and replace it with properly encapsulated AtomicBooleans. I added this comment to the pull request, but I predict that my lazy boss is just going to merge this lovely code anyway. Hopefully I'll have found another job by the time this bites us in the rear end. loinburger fucked around with this message at 02:14 on Dec 12, 2015 |
# ? Dec 12, 2015 01:11 |
|
Lol that he named it a "service" instead of a "pile of globals"
|
# ? Dec 12, 2015 04:51 |
|
fleshweasel posted:Lol that he named it a "service" instead of a "pile of globals" The technical term is singleton.
|
# ? Dec 12, 2015 05:21 |
|
I prefer simpleton. Oh, you mean the code.
|
# ? Dec 12, 2015 05:22 |
|
fleshweasel posted:Lol that he named it a "service" instead of a "pile of globals" /service/dicksucker/gi and watch your codebase become more entertaining.
|
# ? Dec 12, 2015 16:42 |
|
Not sure what this is but it certainly looks ugly
|
# ? Dec 12, 2015 18:39 |
|
looks like machine obfuscated code.
|
# ? Dec 12, 2015 18:47 |
|
Carbon dioxide posted:Not sure what this is but it certainly looks ugly It appears to be a photo of a screen
|
# ? Dec 12, 2015 18:57 |
|
I can tell from the pixels and from seeing a lot of pixels in my time.
|
# ? Dec 12, 2015 19:43 |
|
Carbon dioxide posted:Not sure what this is but it certainly looks ugly That thar appears to be Javascript.
|
# ? Dec 12, 2015 20:44 |
|
baquerd posted:That thar appears to be Javascript. Point stands, then?
|
# ? Dec 12, 2015 21:44 |
|
Well how about that, that's exactly what I said at work today: "this [_0x5b14[0]] function!" I said, over and over again, for hours (or some minor variations thereof).
|
# ? Dec 12, 2015 22:02 |
|
HardDisk posted:Just how do you program without using variables? They call it functional programming.
|
# ? Dec 13, 2015 00:35 |
|
I always considered wild sed|awk|greg chains to be programming without variables. The stream don't stop for readability
|
# ? Dec 15, 2015 12:01 |
|
Lol if you don't have Greg do all work for you.
|
# ? Dec 15, 2015 13:01 |
|
Carbon dioxide posted:Not sure what this is but it certainly looks ugly code:
Impotence fucked around with this message at 21:43 on Dec 15, 2015 |
# ? Dec 15, 2015 21:39 |
|
Saw this. It's art. Sorry if it's a repost, I just saw it. http://stackoverflow.com/questions/1732348/regex-match-open-tags-except-xhtml-self-contained-tags
|
# ? Dec 17, 2015 05:28 |
|
I still think almost everybody on that page misunderstood the actual question. The asker wasn't trying to parse HTML with a regex, they were trying to recognize HTML tags. They essentially wanted a lexer, which would be a first pass towards implementing a parser. You pretty much need a tokenizer that does exactly what that question was asking for to implement a real HTML parser. Doing that was actually the first project in my compilers course when I took it. Edit: Such a thing would be used to transform something like code:
code:
In their case, it looks like they weren't discriminating between specific tags, so it would be transformed into code:
Linear Zoetrope fucked around with this message at 05:46 on Dec 17, 2015 |
# ? Dec 17, 2015 05:33 |
|
I agree. Every time that's linked, I'm just bemused by how quickly stackoverflow's nerdlords sprang to win e-peen by totally misconstruing his question so they can score sick meme slamdunks. The guy just wanted to recognize HTML tags, which is totally possible with a regex, not parse and interpret them. There's lots of ways to write a regex that will match <STUFF HERE> but not <STUFF HERE/>
|
# ? Dec 17, 2015 06:22 |
|
But you don't need to escape <> in an attribute value, so this is perfectly legal (paste it into the W3 validator if you want):code:
vOv fucked around with this message at 06:36 on Dec 17, 2015 |
# ? Dec 17, 2015 06:31 |
|
vOv posted:But you don't need to escape <> in an attribute value, so this is perfectly legal (paste it into the W3 validator if you want): Which is why most lexers are implemented in an alternate syntax where you define a separate regex for each token, and match most-greedy-first (so comments will always consume actual tags)*, since it makes individual regexes less complex because you no longer need to worry about explicitly guarding against comments. But in principle you should still be able to match any single token with a regex (or whatever superset of DFAs modern regexes operate off of). E: Also, the < and > in quotes isn't really a huge issue, it's definitely something a real answer to that SO question should have mentioned, though! * The flex syntax for matching multi-line C comments is actually pretty impressive, since you get to define your own embedded mini-FSM, but I can't recall it off the top of my head. Linear Zoetrope fucked around with this message at 08:41 on Dec 17, 2015 |
# ? Dec 17, 2015 08:34 |
|
Jsor posted:I still think almost everybody on that page misunderstood the actual question. The asker wasn't trying to parse HTML with a regex, they were trying to recognize HTML tags. They essentially wanted a lexer, which would be a first pass towards implementing a parser. You pretty much need a tokenizer that does exactly what that question was asking for to implement a real HTML parser. Doing that was actually the first project in my compilers course when I took it. If they misunderstood the question, it is because the question they think is being asked is asked with regularity. I really don't think they misunderstood the question. I feel like if the OP were working on a tokenizer for a parser they would have anticipated the response and given some explicit indication of that. Or, y'know, responded to some of the people who answered to say "you guys misunderstood."
|
# ? Dec 17, 2015 12:29 |
|
It's still funny, sperglords. :/
|
# ? Dec 17, 2015 14:11 |
|
Blue Footed Booby posted:If they misunderstood the question, it is because the question they think is being asked is asked with regularity.
|
# ? Dec 17, 2015 14:11 |
|
Try posting a question on SO that contains any references to HTML and regexp in any context - one of the respondents will link that exact answer.
|
# ? Dec 17, 2015 14:56 |
|
canis minor posted:Try posting a question on SO that contains any references to HTML and regexp in any context - one of the respondents will link that exact answer. Good. Regex and HTML: Just don't do it.
|
# ? Dec 17, 2015 15:15 |
|
canis minor posted:Try posting a question on SO that contains any references to HTML and regexp in any context - one of the respondents will link that exact answer. Exactly. It's a meme at this point and those dorks were falling all over themselves to pile on. I saw a chart of SO answers once (it was on some webcomic), where they basically categorized SO answers into something like: 1% - Correct answer, conveyed in language so detailed and jargony that only the answerer actually understands it. .1% - Correct answer usable by anyone 50% - Honest attempts to answer the question, but wrong in subtle ways or misunderstanding the question subtly 48.9% - Trolls, jokes, and idiots repeating blog posts about hawt programming opinions or the coolest new library of the week
|
# ? Dec 17, 2015 16:53 |
|
|
# ? Jun 10, 2024 04:17 |
|
My favorite SO moment was when I answered a question and someone commented on it "no ur wrong"... when the question was about the product I built. Gave me flashbacks to argumentative know-it-all students from my CS teaching days. The more things change
|
# ? Dec 17, 2015 17:02 |