[Boards: 3 / a / aco / adv / an / asp / b / biz / c / cgl / ck / cm / co / d / diy / e / fa / fit / g / gd / gif / h / hc / his / hm / hr / i / ic / int / jp / k / lgbt / lit / m / mlp / mu / n / news / o / out / p / po / pol / qa / r / r9k / s / s4s / sci / soc / sp / t / tg / toy / trash / trv / tv / u / v / vg / vp / vr / w / wg / wsg / wsr / x / y ] [Home]
4chanarchives logo
Daily Programming Thread
Images are sometimes not shown due to bandwidth/network limitations. Refreshing the page usually helps.

You are currently reading a thread in /g/ - Technology

Thread replies: 255
Thread images: 28
File: 1443464145946.png (100 KB, 601x623) Image search: [Google]
1443464145946.png
100 KB, 601x623
Old /dpt/ at >>51369628

What are you working on?
>>
Good thread.
First for C.
>>
>>51377307
First for python a shit
>>
>>51377307
First for D
>>
>>51377307
wait did /g/ send the book to guido?
>>
>>51377307
First for Javascript is the future.
>>
5th for Go
>>
>>51377288
>http://pastebin.com/2NiXYpnn


neat

i've found like a dozen twitter accounts for "extremists"

oh wow anon you're so cool you can read someones posts and figure out they belong to isis

so can the fucking rest of us
>>
File: ss+(2015-06-17+at+05.35.38).png (45 KB, 580x571) Image search: [Google]
ss+(2015-06-17+at+05.35.38).png
45 KB, 580x571
>2015
>wanting to work for Google
>>
I finished my regular expression thanks to the help from the websites in the previous thread

PID\|[^\|]*\|[^\|]*\|(L?\d+)\|[^\|]*\|([^\^]*)\^([^\^]*)\^([^\^]*)\^[^\^]*\|[^\|]*\|(\d{4})(\d{2})(\d{2})\|([M|F])


Thanks guys. Now time to put this into a piece of code and never even look at it again.

For the curious. I'm using this as a temporary measure to get all the information out of a PID (patient ID) in a piece of HL7 code.
>>
>>51377363
http://pastebin.com/JQ9KvU6z
>some punk dox
>i'll thake that 1btc now

fucking lmao
these kids going at it hard

pastebin snooping is fun
>>
>>51377182
Setting the line separator $/ to undef causes <> to read the whole file.
local $/;

while (<>) {
print "$_ JEWS\n";
} # prints the whole file and then JEWS
>>
>>51377412
they're just mad they couldn't get a job there. fox and grapes.

google pays very well and has many benefits. it's literally the best place to work on the planet.

they're leading the AI industry and likely will take over the world.
>>
File: j8kkcit.png (30 KB, 599x155) Image search: [Google]
j8kkcit.png
30 KB, 599x155
>>51377420
>http://pastebin.com/JQ9KvU6z
Jesus christ this guy is the reel deelz
>>
File: jean-le-rond-d-alembert.jpg (561 KB, 1924x2394) Image search: [Google]
jean-le-rond-d-alembert.jpg
561 KB, 1924x2394
>>51377412
>can't invent a binary tree on a whiteboard
>>
>>51377427
Ah, that makes perfect sense. Thanks a lot.
>>
>>51377412
>applying for a CS job without basic CS knowledge
>>
File: 1386094988354.jpg (32 KB, 312x342) Image search: [Google]
1386094988354.jpg
32 KB, 312x342
>>51377450
>it's literally the best place to work on the planet
>>
>>51377412
ayyyyy
>>
non-programmer currently learning html here
is html/css a programming language?
>>
File: 1126.gif (992 KB, 389x259) Image search: [Google]
1126.gif
992 KB, 389x259
>>51377558
>>
>>51377591
It's a meme language
>>
>>51377558
kek
>>
>>51377325
> the D
>>
>>51377591
Through some accident, the combination of HTML5 and CSS is Turing complete, but no, it's very stupid to think of them as programming languages.
>>
>>51377631
8=======D~
>>
>>51377558
>tesla
>google
Apple truly is the garbage bin of the industry
>>
>>51377649
wait what?
care to explain that.

(the first part obviously)
i'm a web dev and i've never heard of this
>>
>>51377662
http://beza1e1.tuxen.de/articles/accidentally_turing_complete.html
>>
>>51377412
>code monkey can't invert do CS 101 but feels entitled to a job cause he's done some shitty package manager
my lels
>>
>>51377558
>people like Jordan Hubbard, one of the co-founders of FreeBSD, leave Apple
>people like this guy, unable to use basic CS data structures, join Apple
Explains a lot about the decline of OS X. The worst thing about this retard is that he went to twitter to cry because he failed a fucking job interview. He apparently was convinced that making a very basic package manager in Ruby would guarantee getting a job at fucking Google.
>>
>>51377649
but if I learn the language I am a programmer or web-dev, right?
>>
>>51377756
>I am a programmer
No
>web-dev
If you're satisfied with static web pages
>>
>>51377756
It's a markup language not a programming language.
>>
>>51377677
>http://beza1e1.tuxen.de/articles/accidentally_turing_complete.html

>magic the gathering
>that sql mandlebrot
>apache
holy shit

>pokemon yellow
holy shit thats neato

i'm assuming super mario is also turing complete, since they were able to create pong, and reprogram it via keypresses.

neat shit
>>
File: btfo.png (48 KB, 589x460) Image search: [Google]
btfo.png
48 KB, 589x460
>>51377558
Johnny B. btfos khan acad webmaster
>>
File: 1280631254879.gif (131 KB, 147x121) Image search: [Google]
1280631254879.gif
131 KB, 147x121
>>51377412
>call yourself a software engineer
>can't invert a binary tree
>>
>>51377836
I think I understand what both of those things stand for but I don't understand why html can't be a programming language too
>>
>>51377939
how dou you even invert a binary tree? that shit makes no sense
>>
"Fuck proprietary formats."
--Joe Armstrong
>>
Javascript question:

do function expressions execute once the interpreter comes across them?
>>
>>51377979
just fucking turn it around lmao! I can't believe that loser is working at apple. christ.
>>
>>51378008
so it's just a mirror? gotcha
>>
>>51377979
lmao
>>
>>51377926
>what is harmful to this industry is bad programmers who think they are good
>said jonathan blow smugly
>>
>>51378008
Just?
Swp(node){
var a = node.right;
node.right=node.left;
node.left=a;
Swp(node.right);
Swp(node.left)
}
>>
patt = r"([-]?[0-9]*)([-]?[0-9]*)([+-*/])([-]?[0-9]*)([-]?[0-9]*)"

What's wrong with this regular expression that checks for an operation between two fractions? I'm new at this..
>>
File: 1447632994347.jpg (161 KB, 1462x1462) Image search: [Google]
1447632994347.jpg
161 KB, 1462x1462
>>51377420
>>
>>51378008

So, essentially, this
invert(tree):
if tree == null:
return
swap(tree.left, tree.right)
invert(tree.left)
invert(tree.right)


(note that I'm using pseudocode. My knowledge of Python is meh at best, because I only use it when I'm forced to)
>>
>>51378086
I mean, while making a critically acclaimed videogame doesn't make one a programming authority, that's not all he does. The dude writes compilers for fun...
>>
>>51377307
My Objective-C compiler.

Just implemented type encoding for selectors. Next step is encoding IVAR name, type, and offset for each class. Then I can improve my KVC and KVO implementation for non-id types.
>>
>>51377420
kek

all this effort for 1 btc? is the "hacker" like 12?
>>
>>51377420
>0x
>Doesn't use hexadecimal
>>
>>51378222
I would imagine it was some other kid being like "oh i'll give you 1btc if you can even do x and y u feg", so the "I'll take that one BTC now" was sort of him just being smug.
>>
>>51378118
That is not something you should use regular expressions for.
>>
What is the "h" after a number in assembly? Does it mean "hexadecimal"?
>>
>>51378103
>>51378177
Yep. Just by knowing what recursion is, what's a binary tree and having some problem-solving skills the solution comes easily, even if you haven't picked up an algorithms/data structures book in a while. He was probably expecting a FizzBuzz or something like that.
>>
>>51378273
Yes
>>
>>51378118
(?(DEFINE)(?<I>-?[0-9]+)\/)((?&I)\/(?&I))([+\-\/\*])((?&I)\/(?&I))

Will match the numerator, operator, and denominator regardless of negatives. Spaces not accounted for.
>>
The more CS classes I take the more I just want to jump off this wreckage and do some braindead IT job instead. Programming shit beyond what is directly useful for myself is suffering. Why bother busting your ass building software when you could do support/maintenance and get paid well enough for doing basically nothing but browsing 4chins all day?
>>
>>51378305
just do what you gotta do

whether that be building software or slacking off at a dead end job
>>
>>51378008
>>51378103
Really? Is that all you have to do? And that guy failed at it?
>>
>>51378320
thanks bud
>>
>>51378366
I can't imagine what else "invert a binary tree on a whiteboard" could mean. You can google it to see some quora discussion, but I can't think of what else it could mean..
homebrew is a piece of garbage anyway.. (most of their big patches STILL come from the macports maintainers). everyone should just use pkgsrc and be done with it.
>>
>>51378401
Good god that name and trip is disgusting, please promptly murder-suicide the closest person to you.
>>
>>51378446
I just use it to troll outside of desktop threads a-la vekin and wizbro.
>>
>>51378292
Ah, I forgot to escape. Thanks!
>>
>>51378463
I take back my statement then, I apologize.
>>
>>51377412

>Call yourself a software engineer
>Can't do stuff in Algorithms 101 class
>>
>>51378278

Well fuck, man. My data structures classes were a couple of years ago, so if you asked me about specific types of binary trees (i.e. red-black trees, avl trees) I might draw a blank for a bit. But if you simply described the task "make a mirror of a binary tree", then I cannot see how any competent programmer could fail this task. Shit, I could whiteboard that in C any day.

struct binary_tree;
struct binary_tree {
int data;
struct binary_tree *left;
struct binary_tree *right;
};

void invert(struct binary_tree *tree)
{
struct binary_tree *tmp;

// Recursive base case
if (tree == NULL) return;

// Swap left and right subtrees
tmp = tree->left;
tree->left = tree->right;
tree->right = tmp;

// Recursively invert both subtrees
invert(tree->left);
invert(tree->right);
}
>>
>>51377962
Because HTML semantically describes (marks up) content, it does not describe actions to execute.
>>
let fn = { let gn = lambda (x, y) x; };
New top-level name: fn : All(#T0, #T1) ((#T0 , #T1) -> #T0)
{
let fn = {
let gn = lambda ((x, <none>), (y, <none>)) x;

}
;

}
: All(#T0, #T1) ((#T0 , #T1) -> #T0)
; ModuleID = 'main'

define i8* @sequence() {
main:
ret i8* ()* @sequence1
}

define i8* @sequence1() {
main:
ret i8* (i8*, i8*)* @lambda
}

define i8* @lambda(i8* %x, i8* %y) {
entry:
ret i8* %x
}

Wew!
Time to add builtin functions, then do generation for conditional and loop (easy, just a phi node), then do interop with C and C++ (I'm told it's easy because llvm, we'll see).
>>
>>51378366
i guess he just didn't know what the question meant. but any decent programmer should know what a binary tree is and be smart enough to conclude what it means to invert said tree. if he knew what the question meant but couldn't come up with a solution like >>51378177 he just went full retard.
>>
File: 20121119221755-e41405ae.jpg (56 KB, 600x450) Image search: [Google]
20121119221755-e41405ae.jpg
56 KB, 600x450
>Mfw just got a job interview with Google, (phone interview first)
>Mfw /dpt/ is talking about Google
>2 weeks to get comfortable with Python

Sheesh
>>
Writing a RADIUS server in Python
>>
>>51378583
And here you are posting on /g/ instead on studying.
>>
>>51378635

I just got the news and I'm trying to set up a 2 week curriculum bro.
>>
>>51378652
The early bird gets the worm, and all those other retarded metaphors.
Good luck though man.
>>
>>51378500
the patriarchy is oppressing him
>>
>>51377450
>it's literally the best place to work on the planet.
If you're lucky you get to meet Anita and Zoe, too! So great !!!
>>
>>51378866
Identifying as nullgender fossphile subhuman
>>
>>51378583
>yfw they find 4chan /g/ in your browsing history
>>
>>51378941

Is that a bad thing? Should they find r/python?
>>
>>51378534
I understand that the bottom half is LLVM but what the fuck is going on at the top
>>
>>51378954
They should find pictures of Guido in your fap folder
>>
i'm using this to interpolate between discrete data points. how can i make it extrapolate to a value where x is greater than the largest knot?

>A polynomial spline function consists of a set of interpolating polynomials and an ascending array of domain knot points, determining the intervals over which the spline function is defined by the constituent polynomials. The polynomials are assumed to have been computed to match the values of another function at the knot points. The value consistency constraints are not currently enforced by PolynomialSplineFunction itself, but are assumed to hold among the polynomials and knot points passed to the constructor.

>N.B.: The polynomials in the polynomials property must be centered on the knot points to compute the spline function values. See below.

>The domain of the polynomial spline function is [smallest knot, largest knot]. Attempts to evaluate the function at values outside of this range generate IllegalArgumentExceptions.

>The value of the polynomial spline function for an argument x is computed as follows:
> 1. The knot array is searched to find the segment to which x belongs. If x is less than the smallest knot point or greater than the largest one, an IllegalArgumentException is thrown.
> 2. Let j be the index of the largest knot point that is less than or equal to x. The value returned is polynomials[j](x - knot[j])

http://grepcode.com/file/repo1.maven.org/maven2/org.apache.commons/commons-math3/3.5/org/apache/commons/math3/analysis/polynomials/PolynomialSplineFunction.java
>>
>>51378580
Idk. When I first heard it I though they meant vertically invert it. i.e leaves become roots. That would be more complicated.
>>
>>51378580
>i guess he just didn't know what the question meant
Then he should have asked for clarification, fucks sake
>>
Does
strncpy(array[i], array[i], strlen(array[i]));
actually strip newline chars, or is it useless?
>>
File: what.gif (665 KB, 406x282) Image search: [Google]
what.gif
665 KB, 406x282
My graphical programming professor just told us we can't use C commands in our first obj loader because it's more susceptible to memory errors.

I got it working weeks before he told us this.
>>
>>51377413
honestly, if the regex is that complex just write a parser for it. if you use Lex+Yacc then you can use that to translate most of it without doing much.
>>51378972
not him but it looks like the code just defines a function of type
forall a, b. (a, b) -> a
>>
>>51379062
Damn, that's a good professor, buy him a beer.
>>
>>51379054
Why would it strip newline chars? All it does is copy until it hits the null terminator or the given length.
>>
>>51379054
If you need to strip space at the end of a string write a function.
>>
>>51379088
Can I honestly ask why?
>>
>>51379083
Oh, you're right. I hope that's not the syntax exposed to the end user, in any case.
>>
>>51378972
First line is the input, second line records which names are registered at the top-level, followed by the inferred type of the expression, third line until the other type information is a printout of the transformed AST ((x, <none>), (y, <none>) are the parameters x with no default value and y with no default value; a similar representation is used for calls, where one can specify a value without a name like in fib(3) as opposed to fib(x : 3)). The bottom part is the llvm bytecode output, as you said.
>>
>>51379088
What's wrong with C commands?
>>
>>51379112
Because he advised against using C.
>>
>>51379112
So you can take it away from him again, because it's unsafe.
>>
>>51377320
>what are you working on
>python a shit
i'm curious what the preferred language of someone who can't follow clear instructions is.
>>
>>51379148
It's exactly as he says: C programs, by the very design of C, are extremely prone to memory errors such as memory leaks, memory corruption, buffer overruns, stack smashing, etc. It's a major issue in regular programming, but in GPU programming it becomes critically dangerous because you can end up locking up part of your GPU's memory without recovery until restart, or you can cause your GPU to stop working altogether until a restart.
>>
File: maxresdefault.jpg (96 KB, 1280x720) Image search: [Google]
maxresdefault.jpg
96 KB, 1280x720
I received these digital logic ICs from my uncle a long time ago. In addition there are two analog ICs: LM339 op-amplifier and LM2902 comparator. I made a list of the parts and hunted the datasheets for each one.

HEF4093    4 x NAND Schmitt-trigger
CD4017 decade counter
MC14017 decade counter
HEF4053 3 x 2-input multiplex
74F374 8 x flipflop(D), 3-state output
CD4051 1 x 8-out multiplex
SN74LS156 2 x demultiplex
SN74HC14 6 x NOT schmitt-trigger
M74HC164 8-bit SIPO shift register
CD4029BC Binary/decade counter
CD4019 4 x AND/OR select gate
MAX507 12-bit digital/dnalog converter
LM339 4 x comparator
LM2902 4 x op-amp


I am interested in building some simple circuits with these digital ICs but I do not have much knowledge about the topic. What kind of circuit(s) could be realized with these parts? Could I do a light controller or a tiny solar charger controller?

Pic unrelated
>>
>>51379155
But isn't it more efficient? And less overhead?

>>51379182
That makes sense. The previous professor told us it'd be better to use C. But he had industry experience so probably stuck in his ways.
>>
>>51379182
>but in GPU programming it becomes critically dangerous because you can end up locking up part of your GPU's memory without recovery until restart, or you can cause your GPU to stop working altogether until a restart.
What the fuck does that have to do with writing an .OBJ loader
>>
>>51379171
Maybe brainfuck? It has so few commands that even someone who can't follow instructions shouldn't mess up too bad. A good assembly language, otherwise. Perhaps X# in third position.
>>
>>51379062
Just delete everything you create. How hard is that?
Alternative is to create your own smart pointer. Memory management is only hard if you do not know what you are doing.
There are plenty of tools to help with that anyway. I usually use massif.
>>
>>51379206
It's a graphical class, so it's probably better to teach the students the safer method.
>>
>>51379205
>But isn't it more efficient? And less overhead?
Not necessarily and even if it was in this specific case see >>51379182, the cons outweight the pros.
>>
>>51379062
Please tell me that class teaches OpenGL with immediate mode
>>
>>51379205
>But isn't it more efficient?
no because you can't program a gpu with C anyway. You arrange the elements you want to send to the GPU in C, then offload the work via opengl, directx, cuda, opencl, or some other technology, which performance characteristics are disassociated from the host language.

>And less overhead?
Yes, this part is correct. Using C will reduce the overhead.

>>51379206
>What the fuck does that have to do with writing an .OBJ loader
Presumably he's loading the obj into vram, not merely keeping it in ram. Although the instruction not to use C is probably so that they can build upon their previous work throughout the class without being stuck with a C codebase when real shit starts being worked on. Not that it's much trouble to just use another language's FFI, but better safe than sorry.
>>
>>51377307
First for iOS SpriteKit.

Just finished a very simple clone of FlappyBird in it. I'm really liking iOS/Swift programming, it's extremely easy.
>>
>>51379215
>Just delete everything you create. How hard is that?
holy shit guys, this guy solved decades old dynamic memory allocation problems.
>>
File: 1447376824046.jpg (99 KB, 528x708) Image search: [Google]
1447376824046.jpg
99 KB, 528x708
So /g/, I'm looking to make a really simple OS X app , should I go the Objective-C route or Swift?
>>
>>51379254
hey man. we should team up and make some APPS
>>
Got a question guize, how should I go about implementing the X protocol in JavaScript + Canvas? I seek to build some sort of web-based windows manager for linux servers (this way it would be very light on the server) and for general desktop use of course.
>>
>>51379240
>immediate mode
It's opengl but not immediate mode.
>>
>>51379278
first create the universe. then start removing the code until all that left is what you want
>>
>>51379202
Not thought about this at all, but you could create a clock with the counter maybe. ADC could be used to measure the outside light level to match the conditions. the gates maybe for various settings.

>>51379276
Why would I team up with you?

>>51379269
Swift.
>>
>>51379299
got any actual advice or is this just a meme board? also checked
>>
>>51377335
What book to Guido?
>>
>>51379215
If it were that easy, there would be no need for fancy stuff like parallel non-blocking mark and sweep or CoMTA. One would simply insert a 'delete' when a symbol is last seen in lhs position before the end of its scope.
>>
>>51379310
>Why would I team up with you?
i was being sarcastic you autist
>>
>>51379299
Do I associate my code with this universe or do I start from scratch with a new universe?

How big is the scope of this universe?
>>
>>51379317
See OP
>>
>>51379313
if you are asking how to implement x11 in js, that is the answer you get
>>
>>51379326
>Pic related

But seriously, what's wrong with wanting to create apps and games? I'd love to hear the /g/ meme on this one.
>>
>>51379330
obviously the universe you are building should be a quine, include your code in itself
>>
>>51379333
gee, looks like someone's already (kinda) done it. Should've googled it better
>>
>>51379207
makes sense.
>>
What does it mean if most of my program bugs come from me forgetting to subtract an additional one from an incrementer?
>>
>>51379365
it means you are a bad programmer that fails at a cs 101 course
>>
>>51379365
that the programs you make are small
>>
>>51379343
you're just an amateur codemonkey. you're also a pretentious cunt if you think your "swift skillz" gives you any sort of credibility
>>
>>51379332
awwwww shieeeeet
>>
>>51379402
I was never stating that I had "1337 skillz" or anything. I said I was enjoying learning Swift and was finding relatively easy. I've made a flappy bird clone, that doesn't mean I think i'm a seasoned pro. It means I've learn something and created something that works well.
>>
>>51379252
So at the end of the day is it better to use C if I know what I'm doing with the memory?
>>
>>51379365

git gud at discrete math fampai
>>
>>51379435
no. picking C over C++ is just stupid.

If your application demands performance, then C++ is a good choice.
>>
>>51379473
lmbo
>>
>>51379435
Yes, C is better if you're actually competent.
>>
>>51379434
so what're you complaining about
>>
>>51379526
When was I complaining?
>>
>>51379473
Actually, C++ doesn't really have a purpose. For performance, C is the better choice, when performance doesn't matter, a higher level language than C++ is better.
>>
>>51379473
>>51379515
I'm getting mixed messages I'm probably just going to keep using both until one screws me over and I swear off it forever.
>>
>>51379538
Calm down, anon
There is no need for this kind of behaviour
>>
>>51379559
That will be C++. C can't screw you over, it doesn't do anything behind your back. It's simplicity is its greatest strength.
>>
>>51379538
you're complaining about being called out as an app noob
>>
>>51379573
What about the memory issues.
>>
>>51379556
what C++ performance overhead are you talking about? It only adds when it needs to.
>>
>>51379589
four words: git gud.
>>
File: 1439070950057.jpg (65 KB, 604x453) Image search: [Google]
1439070950057.jpg
65 KB, 604x453
How to learn to translate assembly algorithms to higher-level C algorithms?
>>
Do ctards ever stop?
>>
Do racemixing keks ever stop?
>>
Do tripfags ever stop?
>>
>>51379694
>>51379695

No.
>>
>>51379631
By learning both.
I have mostly done simple stuff in assembly in order to understand C but you can study the output and see if that makes sense.
>>
>>51377459
reading comprehension bro
>>
>>51379589
Need to be on top of your game for that shit.

Make sure your increments are solid, etc etc.
>>
>>51379631
Understand the algorithm, not the assembly. Then you should be able to do it in any language.
>>
File: 1433891629140.webm (240 KB, 600x440) Image search: [Google]
1433891629140.webm
240 KB, 600x440
>>
>>51377307
any fellow mac fags here?
does anyone know of a progam that will keep the sound card in my imac "active" so it never turns off my "headphones"
whenever it goes idle it get a horrible buzzing noise?
I would just play an mp3 file that does nothing, but I would actually like to be able to use itunes, and I want to be able to use the media keys on my keyboard.
any idea where to start?
>>
>>51378583
good luck m8
>>
>>51379589
You need to deal with them by properly doing your job.
>>
>>51379435
If you're making the next AAA game, yes. If you're not, no. Even if you think you know what you're doing with the memory, it doesn't mean your program correctly handles memory.
>>
>>51379556
C++ actually typically has better performance than C if you know what you're doing due to r-value references, and template metaprogramming.
>>
>>51379622
Memsters like to pretend they know anything at all, so they'll often pretend C++ is slower because if you do multiple inheritance or explicit virtual functions a vtable is needed.
>>
>>51380013

Oh, now you've gone and opened a can of worms.
>>
File: Screenshot 2015-11-16 23.35.20.png (145 KB, 1920x888) Image search: [Google]
Screenshot 2015-11-16 23.35.20.png
145 KB, 1920x888
>>51377307
Are ISIS going to kill me?
>>
>>51379018
Don't.

The whole point of spline functions like that is that they're only defined on certain ranges. You can't just arbitrarily extend the domain and expect your results to be worth anything at all.
>>
Total noob here
What's a good offline compilator for java?
>>
>>51380013
Maybe on the paper where fairies sprinkle pixie dust on pure algorithms. In the real world, that doesn't happen. What does happen is a shitload of temporary objects created and destroyed, shitload of calls due to hidden operator overloading and cast operator definitions all nicely packaged in an unmaintainable mess because everyone has a different c++ feature that wants to use in his part of the code.
C is better in this respect because there's no hidden cost to anything. A function call is a function call: you don't have any of those in the piece of code you're looking at? then nothing funny happens behind the scenes. All those string operations look nasty and too much? Good! Now you see the amount of useless shit you're trying to shoehorn in there; doesn't feel nice in plain sight instead of being hidden by constructors and operator overloading, does it?
IOW: git gud
>>
>>51380337
>Good! Now you see the amount of useless shit you're trying to shoehorn in there

'Strings are useless shit' - C users
>>
>>51380337
is that why any medium-sized and above C codebase contains a reimplementation of 30 common datastructures and makes ridiculously heavy use of macros everywhere such that it's literally impossible for anyone but the author to know what's even going on?
>>
>>51380384
If this is all you got, no wonder you're a tripfag.
>>
>>51380448
Yes.
>>
>>51380384
>not #defining constant variables to their string equivalents to save resources and time
>>
>>51380327
>compilator
lol
>>
>>51380327
oracle jdk javac
>>
>>51380485
Give the frog a break, lest he surrenders and stops programming.
>>
>>51380455

It's not all I've got, I was simply reiterating what the guy said.
>>
>>51380448
as opposed to the crapfest of boost and other template heavy monstrosities?
>>
>>51380179
Yes, but your website has not affected that.
>>
>>51380499
templates are the best thing ever anon.
>>
>>51380495
some reading comprehension would help because he didn't say that
>>
>>51380499
As opposed to the, yknow, standard fucking library.
>>
>>51380500
Mr.Bush? Are you trying to fear monger me?
>>
>>51380514
nah, traps are the best thing!
>>
>>51380516

see:

>All those string operations look nasty and too much? Good! Now you see the amount of useless shit you're trying to shoehorn in there

You really don't need any more context. I read just fine.
>>
File: 1334323104542.png (402 KB, 937x2862) Image search: [Google]
1334323104542.png
402 KB, 937x2862
Daily reminder that people still use fortran and the American taxpayer's dollars are keeping it alive:
https://www.llnl.gov/news/nnsa-national-labs-team-nvidia-develop-open-source-fortran-compiler-technology
>>
>>51380544
>All those
but then again, no point in arguing with a tripfag
filtering
>>
>>51380576
Are you retarded or just pretending?
>>
>>51380576
>All those

Yes, as in basic string operations. If you don't think working with strings is fairly fundamental to programming and should be considered 'useless shit' then I don't know what to say.
>>
>>51377412
Nobody here knows how to do this either

Because what the fuck does invert mean in this context?
>>
>>51380631

I'm pretty sure the intended effect is that right child becomes left child, left child becomes right child.
>>
>>51380622
>basic
>working with strings
>fundamental
webtard detected
>>
>>51380660
>lmao text is for webtards
>what is grep
>what it sed
>what is awk

Absolutely fargin kill yurslef.
>>
Ask a C/C++ expert anything!
>>
>>51380667
>implying he writes coreutils on a regular basis
>fundamental
>mad
well memed famley
>>
>>51380694
>>implying he writes coreutils on a regular basis

I'm writing coreutils for the one true operating system, TempleOS.
>>
>>51380667
>what is node.js
>what is mongodb
>what is angular
>what is meteor
>>
>>51380707

Webshitter stuff that I am unfamiliar with, family.
>>
>>51380667
>listening to a wintard kek opine about sed
>>
>>51380718
>pretending
>>
>>51380658
wrong, the original question wanted them to invert the tree so the leaves become roots
>>
>>51379083
I can't desu m8 senpai.

As I said in the previous thread. I need to use AHK. And unless you know of some way I can write a module for AHK in python, than I would be stuck using regex. Because I'm sure as hell not using C++ for as something complicated as this.
>>
>>51380681
How do you prevent the compiler from optimizing certain blocks of code with optimization flags enabled?
>>
>>51380731
>wintard kek

Because I've never used Ganoo/Lingus? I use it all the time. I've got it on a few machines and several VMs. I just use Windows because muh gayming.

>>51380734

I honestly don't know the first thing about web development.
>>
>>51380770
Put them in a separate translation unit and compile that one without optimizations.
>>
>>51380741
Kek.
>>
>>51380788
Shit answer, thanks.
>>
>>51380772
>I honestly don't know
'nuff said
>>
>>51380801
You're welcome, it suits the question.
>>
File: 1447365168666.jpg (81 KB, 1024x1024) Image search: [Google]
1447365168666.jpg
81 KB, 1024x1024
>>51380811

Woah, please stop violating the code of conduct! You are hurting my fee fees.
>>
>>51380834
Why is ze wearing patriarchal, oppressive, and highly problematic gender signifiers? Half of the people in that room are easily raped by this. Just toxic.
>>
File: 1438287718359.png (77 KB, 680x497) Image search: [Google]
1438287718359.png
77 KB, 680x497
can you guys please stop typing in lime green it's hurting my feelers.
>>
>>51377307
So I made an android app and now I want to make some kind of backend for storing users and having them post/get objects. I have no experience of this. Where do I start?
>>
>>51380862
sie hir
>>
Is C just syntactic sugar for assembly?
>>
>>51380956
No.
>>
>>51380956
Assembly is just sytnactic sugar for firing and storing single electrons by hand
>>
>>51380956
Is your mum just syntactic sugar for ur dad?
>>
>>51380971
>for muh dick
ftfy
>>
>>51380970
>single
Try groups of 1000s +-50
>>
>>51379973
>>51379973

Thanks brah
>>
>Wrote hardware emulator today
>Now comes the boring 2 weeks of writing all the automated tests for it
Fun part of job over
Time to quit
>>
>>51380999
Congratulations it's always nice to finish something.
>>
>>51380999
Don't forget documentation and a manual. Make your software a complete package.
>>
I want to learn the basics of Scheme, reading a wiki article about it right now.
>>
>>51381038
>implying anyone would ever see his crap
>>
>>51381047
That's what Linus said about Linux, and Benjamin Franklin about the Declaration of Independence.
>>
>>51381042
here's the basics: (
here's how it ends: )))))))))))
>>
>>51381056
>implying anon made a breakthrough
>>
>>51381059
It's not funny when you have to pass the test involving writing a scheme program on a piece of paper... fucking brackets, man. So many of them.
>>
>>51381071
>implying linus did
>>
>>51381141
>implying he didn't use the gpl
>>
>>51381158
>>51381141
>>51381071
>>51381047

>>51380910
>>
>>51381185
>meme arrows
>>
>>51379764
Aren't algorithms basis for any kind of programming doe
>>
>>51381267
>>>/tumblr/
>>
>>51381276
stop being a dumbass
>>
>>51381303
Stop having less than 2 braincells to rub together.
>>
>>51381321
i'm really sorry for being stupid anon, thanks for enlightening me with your enlightening comments about gtfo-ing back to tumblr. You help a lot two anons tonight, feel good about yourself.
>>
>>51377412
He wrote a fucking shitty Ruby script
>>
There was a link on here a while back to a google drive with a bunch of ebooks most of them computer science related. I organized it and added to it. The only thing is I don't want it ran directly off my personal email, so if anybody has a solution I will gladly share my library.
>>
>>51381465
and the link to the original drive account would be appreciated
>>
>>51381465
Just wrap it up into a torrent add it to a tracker (does /g/ have a tracker?) and post the link here.
>>
>>51381533
>leaks ip
>>
>>51381539
>everyone on /g/ is an evil h4X0r who will write a GUI to take over your mainframe.
If you are that scared use a proxy and stop seeding after the first few people finish the download and are seeding.
>>
>>51378008
Thats incrediably trivial. Also, what's the point of that, the connectivity hasn't changed.
>>
NEW THREAD >>51381637


NEW THREAD >>51381637


NEW THREAD >>51381637
>>
hey guys, get a load a this >>51381648

what a dumb cunt
>>
>>51379254
hahaha faggot
>>
File: vlcsnap-2012-09-17-22h29m16s147.png (482 KB, 1024x576) Image search: [Google]
vlcsnap-2012-09-17-22h29m16s147.png
482 KB, 1024x576
Guys, what was that website that had guides/tutorials for programming languages? It was red if I remember correctly. Sumimasen for being slightly off topic
>>
>>51380254
what else do you suggest then? needs to be better than linear extrapolation
>>
>>51381648
You may be retarded
Thread replies: 255
Thread images: 28

banner
banner
[Boards: 3 / a / aco / adv / an / asp / b / biz / c / cgl / ck / cm / co / d / diy / e / fa / fit / g / gd / gif / h / hc / his / hm / hr / i / ic / int / jp / k / lgbt / lit / m / mlp / mu / n / news / o / out / p / po / pol / qa / r / r9k / s / s4s / sci / soc / sp / t / tg / toy / trash / trv / tv / u / v / vg / vp / vr / w / wg / wsg / wsr / x / y] [Home]

All trademarks and copyrights on this page are owned by their respective parties. Images uploaded are the responsibility of the Poster. Comments are owned by the Poster.
If a post contains personal/copyrighted/illegal content you can contact me at [email protected] with that post and thread number and it will be removed as soon as possible.
DMCA Content Takedown via dmca.com
All images are hosted on imgur.com, send takedown notices to them.
This is a 4chan archive - all of the content originated from them. If you need IP information for a Poster - you need to contact them. This website shows only archived content.