|
Soricidus posted:if you don't think other people's coding is offensive then I don't even know what to say 'other people's coding' includes 'your own code from six months ago'
|
# ? Jul 17, 2016 23:20 |
|
|
# ? May 24, 2024 18:11 |
|
fritz posted:'other people's coding' includes 'your own code from six hours ago'
|
# ? Jul 17, 2016 23:21 |
|
hobbesmaster posted:'other people's coding' includes 'your own code from six minutes ago'
|
# ? Jul 17, 2016 23:22 |
|
defensive semicolon
|
# ? Jul 17, 2016 23:25 |
|
hey terrible game programmers: the guy behind open.gl just made a vulkan tutorial and it's good https://vulkan-tutorial.com/Introduction
|
# ? Jul 18, 2016 00:12 |
|
anthonypants posted:never go on reddit can't hear https://www.youtube.com/watch?v=DOqb_UzJSUQ
|
# ? Jul 18, 2016 01:29 |
|
Uh oh open watcom's sampler doesn't support dos32a, just dos4g and phar lap how am I going to profile my rasterizer now
|
# ? Jul 18, 2016 02:21 |
|
Luigi Thirty posted:Uh oh open watcom's sampler doesn't support dos32a, just dos4g and phar lap time to make a profiler
|
# ? Jul 18, 2016 02:49 |
|
MALE SHOEGAZE posted:i am getting mad at a stupid discussion on reddit well back in the early days you had to restart rails every 200 requests due to all the memory leaks, so being able to make it to 50k sounds impressive to people used to that
|
# ? Jul 18, 2016 03:21 |
|
Luigi Thirty posted:Uh oh open watcom's sampler doesn't support dos32a, just dos4g and phar lap there's a guy on SO who would be happy to tell you to just run it in a debugger and pause the program's execution occasionally
|
# ? Jul 18, 2016 03:22 |
|
Plorkyeran posted:well back in the early days you had to restart rails every 200 requests due to all the memory leaks, so being able to make it to 50k sounds impressive to people used to that sure if you count a request as something that doesnt do anything, which is a stupid way to measure the performance of a web application.
|
# ? Jul 18, 2016 03:28 |
|
mongodb benchmarks against /dev/null do whatever you want
|
# ? Jul 18, 2016 03:30 |
|
for performance or durability?
|
# ? Jul 18, 2016 03:33 |
|
YeOldeButchere posted:for performance or durability?
|
# ? Jul 18, 2016 03:53 |
|
Bloody posted:mongodb benchmarks against /dev/null do whatever you want Except you're more likely to get data out of /dev/null than MongoDB.
|
# ? Jul 18, 2016 04:08 |
|
haha, python lets you do THIS >>> a = 0 >>> b = 1 >>> a, b = (b, a) >>> print a, b 1 0 gently caress swap routines forever
|
# ? Jul 18, 2016 04:11 |
|
What's wrong there
|
# ? Jul 18, 2016 04:30 |
|
hobbesmaster posted:skip to the end of terrible .net decisions and just use c++/cli trigger warning this poo poo please, being forced to use c++/cli is what made me leave my previous job
|
# ? Jul 18, 2016 05:30 |
|
"why would we use c# when we already know c++?" lomarf. what a freaking pile of lomarf that place was
|
# ? Jul 18, 2016 05:31 |
|
Bloody posted:What's wrong there my guess is that syntactically it looks a bit like an intrinsic way to do assignments serially on a line so you might expect that both values would end up the same due to one operation being done first. instead it's actually a swap which is a little surprising to see come out of a plainish looking assignment statement.
|
# ? Jul 18, 2016 05:43 |
|
fritz posted:'other people's coding' includes 'your own code from six keypresses ago'
|
# ? Jul 18, 2016 05:45 |
|
the python destructuring swap seems fine to me although usually if youre using a swap in any language and it's not some low level optimization poo poo youre probably doing something hosed up
|
# ? Jul 18, 2016 05:51 |
|
comedyblissoption posted:although usually if youre using mutability in any language and it's not some low level optimization poo poo youre probably doing something hosed up
|
# ? Jul 18, 2016 06:36 |
|
picked up an old book Principles of Interactive Computer Graphics
|
# ? Jul 18, 2016 07:00 |
|
abraham linksys posted:i mean what's the other option, design a new compile-to-js language? write a new browser that runs ocaml natively? just ship apps and stop trying to cram "apps" into the browser you don't think Facebook would be where they are today if they didn't have a native iOS app on day one, do you?
|
# ? Jul 18, 2016 08:38 |
|
pretty sure the fb apps use react native or whatever it's browsers al the way down
|
# ? Jul 18, 2016 09:52 |
|
cram apps into the browser crammed into an app imho
|
# ? Jul 18, 2016 09:53 |
saw in picture thread how does this even happen
|
|
# ? Jul 18, 2016 09:58 |
|
kalstrams posted:saw in picture thread I'm guessing machine translation
|
# ? Jul 18, 2016 10:09 |
|
LeftistMuslimObama posted:my guess is that syntactically it looks a bit like an intrinsic way to do assignments serially on a line so you might expect that both values would end up the same due to one operation being done first. instead it's actually a swap which is a little surprising to see come out of a plainish looking assignment statement. I would be super confused if the state of a variable changed halfway through a statement
|
# ? Jul 18, 2016 10:33 |
|
LeftistMuslimObama posted:my guess is that syntactically it looks a bit like an intrinsic way to do assignments serially on a line so you might expect that both values would end up the same due to one operation being done first. instead it's actually a swap which is a little surprising to see come out of a plainish looking assignment statement. i wouldnt expect that both values end up the same. mumps broke your brain.
|
# ? Jul 18, 2016 10:40 |
|
is that even mutation, or is that shadowing? it's been a while since i've done python
|
# ? Jul 18, 2016 10:42 |
|
fart simpson posted:i wouldnt expect that both values end up the same. mumps broke your brain. lol it's too late LMO, you're already unemployable everywhere!
|
# ? Jul 18, 2016 10:54 |
|
gonadic io posted:is that even mutation, or is that shadowing? it's been a while since i've done python i dont think its anything fancy resolution of variables is left to right, except in assignment where the right hand side is resolved first
|
# ? Jul 18, 2016 11:23 |
|
http://robotframework.org/robotframework/latest/RobotFrameworkUserGuide.html#keyword-namesquote:Keyword names used in the test data are compared with method names to find the method implementing these keywords. Name comparison is case-insensitive, and also spaces and underscores are ignored. For example, the method hello maps to the keyword name Hello, hello or even h e l l o. Similarly both the do_nothing and doNothing methods can be used as the Do Nothing keyword in the test data. in other words to be pretty sure that touchButt method is not used anywhere, you have to grep for (case insensitevely) code:
|
# ? Jul 18, 2016 13:10 |
|
Bloody posted:What's wrong there sorry for being vague about that. the idea is that it swaps the value of two variables without requiring me to declare a third variable, because the syntax forms and then unpacks an anonymous tuple with the results. you couldn't do that with 1-to-1 assignments. E: I was using it to do a really short fibonacci thing: Python code:
LordSaturn fucked around with this message at 13:17 on Jul 18, 2016 |
# ? Jul 18, 2016 13:14 |
|
Hello thread, can I post some bad code for you to tell me what I'm doing wrong/how to make it better? Im currently trying to clean a list of names in a database. Since I'm just a stupid grad student (a social sciences one at that) something like the code bellow has always been good enough for what I want to do but now I'm trying to use it on a larger dataset its taking loving ages and its clear that I am probably doing this in a horrendously inefficient way. code:
|
# ? Jul 18, 2016 13:24 |
|
vodkat posted:Hello thread, can I post some bad code for you to tell me what I'm doing wrong/how to make it better? how are you loading the data? you need to be loading the data in batches, processing a batch, outputting a batch, and loading the next batch. it looks like you're loading everything into the data variable and then processing in one go, which won't for large datasets also it could be something dumb in your code but i don't know Python well enough to tell you
|
# ? Jul 18, 2016 13:32 |
|
kalstrams posted:i love that c++ has a thing outright called "defensive coding" C too. for example if a function returns -1 for failure, you don't check == -1, you check < 0. if it returns 0 for false and 1 for true, you check != 0 instead of == 1. also when a function returns both a success flag/error code and a value through a pointer, you don't trust the returned value if the function reports success, you explicitly check that it's valid/non-null/etc. which can turn a crash into a controlled failure
|
# ? Jul 18, 2016 13:41 |
|
|
# ? May 24, 2024 18:11 |
|
kalstrams posted:i love that c++ has a thing outright called "defensive coding" so does ruby, to be fair
|
# ? Jul 18, 2016 13:45 |