Comment on: I have learnt Java, and am undertaking CS50 in a year. AMA about self-learning Java or programming using free resources.
0 08 Jun 2017 16:53 u/SelfReferenceParadox in v/programmingComment on: Ask Programming: if you ever got burnt out in this job or hobby, how did you get back into it?
Exactly, find a new or weird idea that sucks you right in.
Comment on: I made a virtual machine emulator with a custom ASM spec based on z80 in raw Python
poorly
Comment on: How many of you can still read your own code you created years ago?
I'm at the point where it's readable, but incredibly poorly written. I've still got an algorithm I translated from Python to C about a year ago, saved just for giggles. It's a direct translation that mallocs new objects where Python created new ones, and leaks so much memory it's barely usable.
Comment on: I made a virtual machine emulator with a custom ASM spec based on z80 in raw Python
ST B 121
ST C 101
PR B
PR C
Comment on: I made a virtual machine emulator with a custom ASM spec based on z80 in raw Python
fucking vmposters, get off my board
Comment on: Divide a number by 3 without using *, /, +, -, % operators
It's worth noting that div() is from a time when compilers weren't smart enough to merge a mod and a div into a divmod.
Comment on: When do you actually make programs
It would also be a good intermediate step to try and learn more about python's assembly, but there aren't many resources for doing that online. Assembly is good because it teaches you what's going on inside your computer, so it would be a good intermediate step to learn what happens to run python code.
Comment on: We need more programming challenges. We should start off small: First non-repeating character of a string. Any language you like.
What he means is that the code is written the way you'd write it in C. In Python the preferred method would probably be more functional.
Comment on: We need more programming challenges. We should start off small: First non-repeating character of a string. Any language you like.
If we're going that route, isn't C just viewed as Assembly?
Comment on: We need more programming challenges. We should start off small: First non-repeating character of a string. Any language you like.
In Haskell:
nonRepeat s = head $ filter (\c -> 1 == length (filter (==c) s )) s
Comment on: Got a game for you low-level programming NERDS
The game is both incredibly good and incredibly hard.
Comment on: Creating an AI that writes and improves programs
While this is really awesome, I don't think it's going to be replacing actual programmers anytime soon.
Comment on: Does the Go programming language have any future?
Shoot, you're right, edited.
Comment on: Does the Go programming language have any future?
C master race.
Comment on: Does the Go programming language have any future?
The type system is not as rigid as C/C++
IDK about C++, but C's type system is pretty darn relaxed. You can easily convert a floating point number to a pointer, then use that as an index into the array 5.
double x = somenumber;
printf("%u",5[*(signed*)&x]);
Comment on: You are a programmer and you like Trump, I found the language for you: TrumpScript
Except that this is actually mocking him.
Comment on: Another bigot joining Github. Inclusiveness doesn't include white men.
Holy shit it works!
Comment on: Hate GitHub being taken over by gender politics? Don't worry, you're not alone.
Bitbucket seems to be pretty ok.
Comment on: What Is "Memory Stomp"?
Another fun one:
for(byte i = 0; i < 256; i++)
Comment on: golang code of conduct proposal
This kind of utter bullshit makes me mad in a very specific way. A programming language should just be a programming language. No politics, just a specification and maybe a compiler/interpreter, etc. If a community dedicated to a language wants to have it's own stupid microagression rules, I would disagree, but fine, whatever, it's just a website. But you can't just go making that part of the language itself. I almost feel like this would be breaking the sanctity of the language. In the end, all a language is is a collection of rules for a computer to follow to get meaning out of some text/flowchart/whatever. Computers can't understand politics, so keep that garbage away!
</rant> </anger>
Comment on: Dumb Beginner HTML Question
Just to clarify for OP, I think > should render as '>'. (a bug in Voat?)
Comment on: Starting off in C++
Yeah, C's great because you have to have some ideo of what's underneath all the abstractions, so you have a better idea of what's going on when you use something like C++.
Comment on: What are some programming jargon everyone should be aware of?
I remember once mentioning I had used 'hacky' code to my mother once, and dispite my efforts to explain the term to her (and getting two new computers since then) she still blames any issues I have on it.
Comment on: Is there an algorithm to represent how a "kidney exchange chain" works?
Just off the top of my head, it sounds to me like this may reduce to the Travelling Salesman Problem, making this a very difficult problem to solve for large data sets, like you wanted. If you're OK with getting a non-optimal answer, some kind of heuristic.
Comment on: [Help] Complete noob here; want to know how you can easily fake console text for filmmaking purposes
Not quite what you want, but hackertyper.net is relevant.
Comment on: What do you guys think of NASA's programming guidelines? Are they too strict or do they make sense when code correctness is life-or-death?
Exactly. These rules are for space, most programming doesn't need them.
Comment on: VOAT back-end?
I always just assumed it was just Jeff Atwood typing real fast.
Comment on: Hey /v/programming - What's your favorite language to program in and why?
I'm partial to C myself. I'm the kind of lunatic who needs to be able to 'see' the Assembly from inside the programming language, so I tend to find things like C++ too opaque.
Comment on: Coder vs Programmer
I love making softwares!
Comment on: Hi everyone!
main() {
puts("C++ scum");
}
Did you know that array[index] and index[array] do the same thing in C?