[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
/dpt/ - 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: 33
File: DPT.png (389 KB, 934x1000) Image search: [Google]
DPT.png
389 KB, 934x1000
What are you working on, /g/?

Old: >>52533639
>>
>>52535473
First for D
>>
How much ocaml code have you written today, /dpt/?
>>
I am currently working on motivation.
>>
What is polymorphism, /dpt/?
>>
>>52535473
Reminder that >>52533934 is a spineless, shitposting faggot.
>>
STATIC TYPING

NO TYPE INFERENCE

JAVA ÜBER ALLES

SIEG HEIL
>>
>>52535473
#include <iostream>
using namespace std;

int main()
{
int cards, score = 0;
char c;
char userChar;

do
{
cout << "How many cards do you have? enter 2,3,4, or 5" << endl;
cin >> cards;


if(cards >= 2 && cards <= 5)
{

cout << "Enter your card(s): (2-10, t, j, q, k, or a)" << endl;
cin >> c;


I'm trying to write a program that lets the player play blackjack. they enter the number of cards they have, and then they're supposed to enter the value of their cards. I would like for them to enter more than one value, but at the moment it only allows me to input char c, how do I go about placing the user input number (cards) in that character?
>>
>>52535510
Subsitutability.
>>
File: dd.jpg (24 KB, 300x250) Image search: [Google]
dd.jpg
24 KB, 300x250
My dad caught me masturbating to interracial porn.
>>
>>52535511
Nice contribution to the thread, faggot. Wow what a nice argument you got.
>>
>>52535510
like if you want a pet and you just want any pet then someone can give you a dog or a cat or a guinea pig etc as long as it's a domesticated animal. that's polymorphism, when different things can all be used as some other thing.
>>
File: There is no need to be upset.jpg (189 KB, 1887x1810) Image search: [Google]
There is no need to be upset.jpg
189 KB, 1887x1810
>People going autistic over whether or not a language is turing-complete
>People arguing that engines used by AAA developers are bad and only used by shitty indie devs

are you all fucking autistic or something
jesus Christ
>>
File: mpv-shot0018.jpg (226 KB, 1920x1080) Image search: [Google]
mpv-shot0018.jpg
226 KB, 1920x1080
>>52535533
My whole family caught me masturbating to traps.
>>
>>52535510
I have a variable whos value is 2.
If I parse it as an integer, it's 2.
If I parse it as a character, it's B.
So this variable, is B (or 2), right?
So that means that B + B is D. Or 4. It's the same thing, because the variable is polymorphic.
>>
>>52535541
a fucking companion app where you buy clothes or whatever for your cod of doody doll doesn't count as a AAA game fucking shitter
>>
>>52535568
Man anon you're getting pretty heated over this
How about you show me all the games you've made with your custom-built efficiency(tm) engine :^)
>>
>>52535535
Keep stalling.
>>
>>52535524
nevermind, I figured it out.

if I just throw in
for(i = 0; i <= cards; i++) {


it lets me run through the code multiple times
>>
File: 1446239690428.png (115 KB, 256x256) Image search: [Google]
1446239690428.png
115 KB, 256x256
>>52535589
Keep feeding me butthurt.
>>
>>52535580
>if you thought that movie was so bad why don't you make one better yourself
>if you thought that chef was so bad why don't you cook a better meal yourself
i'm never posting my games on 4chan and i don't have to prove myself anyway
>>
>>52535563
My traps caught me masturbating my whole family
>>
>>52535568
Some successful games (and games made by successful companies) made in unity:
Kerbal space program
cities: skyline
polybridge
ori and the blind forest
oddworld: new 'n tasty
beseige
rust
Game of Thrones

>>52535619
But you're not calling the chef bad, you're saying that his meat isn't good enough to be considered real meat.
>i'm never posting my games on 4chan and i don't have to prove myself anyway
Sure thing, buddy :^)
have fun with your custom-programmed efficiency(tm) engine in wrongville where you don't actually ever develop real games
>>
>d* has started posting in /dpt/ as well
>>
File: stop.jpg (33 KB, 400x200) Image search: [Google]
stop.jpg
33 KB, 400x200
>>52535618
>Gets offended when called a faggot, tries not to cry, cries a lot
>Calls other people faggots anyway
>Calls other people butthurt anyway
>Still can't back up their own point given plenty of time
>"Well I'm just not looking for evidence"

Just let us know when you find it, okay hun?
>>
>>52535667
none of those are AAA games

if the chef is serving me a plastic dog toy shaped like a cartoon piece of meat then i'm well in my right to say that it's some shitty """"""""meat""""""""
>>
Holy shit ya'll have to tone down the autism and start talking about programming in a non-theoretical sense
>>
File: 1453251254061.png (281 KB, 535x466) Image search: [Google]
1453251254061.png
281 KB, 535x466
>forced to use Ant
>>
>>52535712
like how to fizzbuzz?
>>
File: 1445387223188.jpg (44 KB, 444x322) Image search: [Google]
1445387223188.jpg
44 KB, 444x322
>>52535673
wat. Raspberry pi has GPIO pins and debian out of the box...
>>
>>52535709
>none of those are AAA games
and none of them have to be. Unity is not a AAA engine. That doesn't make it bad.
The chef isn't serving you a plastic dog toy cartoon-shaped piece of meat, you're walking into a midrange steakhouse and complaining when they don't serve actual kobe beef from japan.
>>
>>52535720
ok?? on my phone i can program some neat ass games i don't see that happening on a $5 rasp pi
>>
>>52535737

You run debian on your phone?
>>
>>52535737
why are you here other than to just be ignorant?
>>
>>52535733
this is one of those trolls where you move the goalposts at the last second, isnt it?
>>
>>52535473
Just got home from twiddling build configs for 8 hours at work. Not sure if I can motivate myself to program tonight.
>>
>>52535759
no but android is kinda linux. is there something special about debian?

>>52535760
just wondering what you're using those things for??
>>
>>52535765
No, I've been saying this from the start

>>52535328
>Sure, it's not a AAA engine, but that's not what the argument's about.
The argument was about whether or not unity is a useful/valid game engine, and it is. Not for everything, not for AAA development, but it's a legitimate engine and AAA developers do use it.
>>
i had an anal orgasm for the first time today

i feel like my love of programming has been rekindled

i'm never going back to girls
>>
.>>52535786
>is there something special about debian

oh god
>>
>>52535737
When is the last time you compiled something on your phone?
>>
>>52535789
It's as much a valid game engine as pure python (not python with C bindings) is a valid game programming language.
>>
>>52535800
i also have a computer, silly
>>
>>52535564
please be my teacher because I understood that very well
>>
>>52535791
Unorthodox, but it's probably best to shove the JS books up your ass rather than actually read them.
>>
File: lost-control.jpg (54 KB, 485x364) Image search: [Google]
lost-control.jpg
54 KB, 485x364
>>52535816
>missing the point
>>
>>52535819
it doesn't really cover polymorphism as used in OOP though
>>
>>52535816
>on my phone i can program some neat ass games
I'll ask again, when is the last time you compiled something on your phone?
>>
>>52535791
w-what language?
>>
>>52535802
But that's not true at all, anon. Unity is consistent, relatively easy to use, and is reliably good at what it does. Is it AAA-quality? nah. But again, it doesn't need to be.
Unity is damn good at what it does.

>>52535819
Sorry anon, I'm not too good with polymorphic concepts beyond the basics.
>>
>>52535832
>spergically nitpicking about how i worded my 4chan post which took literally seconds to write
>>
>>52535824
what's wrong with JS exactly?
>>
>>52535836
see >>52535849

clearly you know what i meant or you have severe sperger
>>
File: fuck you.jpg (53 KB, 1024x578) Image search: [Google]
fuck you.jpg
53 KB, 1024x578
>codeeval scores for C solutions are 1ms and 640b of memory usage in a worst case scenario
>site switches from valgrind to a docker based sandbox test system that purposefully inflates C scores
>hello world now runs in a minimum of 50ms and uses 140000 bytes of memory

Fucking web dev faggots man.
>>
>>52535849
the point is you can compile programs on a raspberry pi and you can't on your phone... idiot
>>
>>52535856
dynamic typing
>>
>>52535791
I bet you love dynamic typing and thought of us static typed alpha programmers dominating your boipussy.
>>
>>52535863
but what's the point when you already have a full-fledged compooter?? and i'm pretty damn sure you can compile programs on smartphones
>>
>>52535858
You said you can program stuff on your phone, so either correct your post or answer the question:
When is the last time you compiled something on your phone?
>>
Are these threads always this autistic or is this a particularly bad day
>>
>>52535859
>playing someone's shitty programming game instead of building something useful
>>
>>52535872
>static typed alpha programmer
more like a Go-pher looking for a hole
>>
>>52535868
why is that bad?
>>
>>52535842

C#, C++

>>52535872

i do, the boypussy part, not the dynamic typing part
>>
>>52535887
it's a bad day. I'm surprised the anti-raspberry pi retard has lasted this long.
>>
>>52535891
>Go
alpha programmers, not memelanguage shills
>>
>>52535893
because more run-time errors = bad
>>
>>52535887
i think it's gotten a lot worse lately

i, the misunderstood genius autist have met my arch-nemesis - the supersperg: >>52535884
>>
>>52535856
http://code.tutsplus.com/tutorials/top-10-things-that-javascript-got-wrong--net-9266

http://johnkpaul.github.io/presentations/empirejs/javascript-bad-parts/

http://simpleprogrammer.com/2013/05/06/why-javascript-is-doomed/

http://baudehlo.com/2011/03/31/whats-wrong-with-node-js-and-javascript/

https://news.ycombinator.com/item?id=7516005

Next time, just google it.
>>
>>52535893
I personally dont like it. Js has some really neat features that I want other mainstream languages to adapt but I hate using it because I can never tell the type of anything.
>>
>>52535856
security flaws
>>
>>52535930
>Js has some really neat features


like what?
>>
>>52535921
>"Javascript is done for!" says increasingly nervous man for 7th time this year
>>
>>52535914
I don't think anyone else in this thread is near enough to your level to understand what you mean without you explaining yourself properly.

So either tell us what you meant, or explain how a phone is better for developing software than a full debian install?
>>
>>52535819
Again, polymorphism is about being able to substitute one thing for another.

For example, polymorphism in OOP is about being able to use an instance of a class in place of an instance of its superclass or an implemented interface. This gets you different behaviour without having to modify the code that uses it. For example, an algorithm expects a list, and you can give it an array-based list or a linked list, or anything that has the same properties as a list.

Polymorphism in generics is about substituting something (usually a type) into a "hole" in a piece of code. So you can write a single list class and use it to construct lists storing integers, lists storing strings, etc.
>>
>>52535950
Let us dream.
>>
>>52535950
Oh no, opinions I disagree with! On the internet!

If people don't have time to have a search for the cons of a given language themsleves, I'm not gonna waste my time explaining it in my own words when a 10 second trip to google is fine.
>>
>>52535952
my phone has superior specs to the pi zero, enabling me to develop fairly advanced and complex computationally demanding games. since i already have a computer, i don't see a need to buy a pi zero. i'm just wondering what you guys are using them for?
>>
>>52535846
Found the paid unity shill.
>>
File: Screenshot_2016-01-20-20-29-12.png (84 KB, 1080x1920) Image search: [Google]
Screenshot_2016-01-20-20-29-12.png
84 KB, 1080x1920
>can't compile on a phone
>>
>>52535992
>thinking paid shills exist on 4chan of all places
>thinking that if they did exist, they'd be targeting /dpt/
christ
>>
>>52536006
Thank you mister Rajesh. 40 rupees have been deposited in your account. Please continue the good work.
>>
File: disagreement-hierarchy.jpg (92 KB, 679x516) Image search: [Google]
disagreement-hierarchy.jpg
92 KB, 679x516
>>52535992
>>
>>52535990
My penis has better specs than your penis, that doesn't make it better at developing software necessarily.
Please explain how your phone is better for developing software than a vanilla linux install on, for example, a Raspberry Pi?
>>
File: 200_s.gif (23 KB, 301x200) Image search: [Google]
200_s.gif
23 KB, 301x200
>>52535990

The Raspberry Pi Zero:

- Is 5 bucks
- Less than 1 watt power consumption (as low as 200 mW)
- Has GPIO
- Runs Linux
- Easy to run headless
>>
>Unity™ is awesome!
And in the same post:
>I know nothing about programming.
>>
>>52536006
meh unity is kinda an amateurish operation i wouldn't be surprised if the CEO himself posted on agdg from time to time at least. and that post does read more like a shill wrote it than some fanboy kid
>>
>>52535921
I'd rather hear why you think it's bad, anon.
>>
>>52535946
Functional shit mostly. First class functions, promises, lambda notation (=>), event driven program flow, for example. Plus as a language, it feels really flexible, which can be a good thing or a bad thing.
>>
>Unity3d
literal garbage

UE4 or SDL2 or get out
>>
>>52536052
I'm neither a shill nor a fanboy. I actually don't like unity all that much, it's too restrictive. I was just arguing the (accurate) point that it's a legitimate engine, because people having autism-attacks over efficiency is funny as fuck.
>>
>>52536048
>- Is 5 bucks
In an ideal world, it's $5 + the cost of all the components you have to supply yourself.
In the real world, it's $45 + the cost of all the components you have to supply yourself.

Just buy a real raspi or a better prototyping board.
>>
>>52535999
Nobody said they can't do it, we were just asking Captain Superior Spec when's the last time he compiled anything.
>>
>>52536048
but what do you USE it for???????????????

>>52536047
how is my phone with a ~150 GFLOPS GPU not better for developing nice ass games than your raspberry pi?
>>
>>52536076
>I actually don't like unity all that much, it's too restrictive
>Sorry anon, I'm not too good with polymorphic concepts beyond the basics.
hmmm
>>
>>52536076
it is *an* engine. just because it is an engine, doesn't mean it's i quote "damn good at what it does".
>>
>>52536048
Heard the zero requires you to buy a lot of addons so it's not really $5
>>
>>52536056
Whenever I see JS code, it reminds me of PHP.
That's reason enough to not touch it.
>>
>>52536098
do you think programming is just for games? Do you even hardware develop nigga?
>>
>>52536093
and everyone with a brain could infer what i meant or didn't care about such a useless piece of information so they didn't have to ask more than at most one time.
>>
>>52536111
Unity is restrictive in really weird unexpected ways, namely how you can't use specific shaders or access certain data to prevent you from writing your own lighting system on the free version. I'm sure the free version is better, but I can't afford that shit so it might as well not exist as far as I'm concerned

>>52536119
It is damn good at what it does, and what it does is knock out reliable & stable multiplatform okay-looking games to a dickload of platforms while integrating resource management. If graphics aren't the forte of your game (I.E. it's anything other than a AAA title) it's a really good option.
>>
>>52536124
>phone charger
>blank sd card

wew
>>
>>52536130
That is literally the gayest fucking reason i've ever heard for not touching either.
>>
>>52536051
that's what engines are for, friend.
>>
>>52536140
now we're getting somewhere. what kind of hardware development are you doing, if i may ask?
>>
>>52536076
what's a better alternative?
besides ue4 and gamemaker.
>>
>>52536098
Maybe if you stop dodging the questions about how you use your phone to develop games, we'll answer yours too.

Having better hardware doesn't mean you have the first clue what to do with it, or that it can even be utilised to it's apparent potential.
I can't tell you how your phone is not better, if you first don't tell me how you use it yourself.

The Pi is used like any other linux distro, just for much less money and with whatever hardware you like, rather than a shitty 7" touchscreen.
>>
>>52536151
a nigger is good at what it does: doing niggery things.
>>
>>52535982
>cons of javascript
>articles from 2011

I don't even like the fucking thing, but come on.

2011 was 9 years ago.
>>
>>52536124
depends on what you do with it
if all you need is the gpio you just need a power supply, and sd card.

there might also be some nice uses for the zero as a usb client
>>
>>52536151
>you can't use specific shaders or access certain data to prevent you from writing your own lighting system on the free version
LMFAO KEKED HARD FUCKING KILL YOURSELVES SO THAT'S WHY EVERY UNITY GAME LOOKS LIKE CRAYON ASS

AND THE "FREE" VERSION STILL TAKES 5% ROYALTIES FROM YOU DOESN'T IT? LMFAO KILL YOURSELF ENGINEBABBIES
>>
>>52536090

Maybe right now they cost 45 bucks from ebay scalpers, but when the Tony Montana gets the new shipment of Pis from the Chinese in the next couple of weeks, it will go back to 5 dollars plus an SD card and a couple of cables.

>>52536098

I don't even have one yet. I want one so I can set up a server to run PhantomJS from my house to flood Kahoot.it games at my school with my phone
>>
>>52536167
building a spectrum analyzer also using it for bitscope
>>
why does the array just copy element [1] into elements [1] through [10] making them all the same at the push_back function? Where did I go wrong there?

import ctypes

class DArray:

def __init__(self):
self.n = 0
self.cap = 1
self.A = self.make_array(self.cap)

def push_front(self, obj):
if self.n == self.cap:
self.resize(2*self.cap)
for i in range(self.n):
self.A[i + 1] = self.A[i]
self.A[0] = obj
self.n += 1

def resize(self, c):
B = self.make_array(c)
for k in range(self.n):
B[k] = self.A[k]
self.A = B
self.cap = c

def make_array(self, c):
return (c * ctypes.py_object)()

#create the array object
a = DArray()

#add 10 values to the end of the array, append works so its omitted
for i in range(10):
a.append(random.randint(1, 100))

#add one random value to the front of the array, this doesnt work
a.push_front(random.randint(1, 100))
>>
>>52536150
Well you have a brain, don't you? Why don't you infer what you meant and tell us all?

Or maybe I can work it out for you. You said you develop games, but what you meant is you play angry birds and bejewelled a lot.
The only thing you've developed is a dependency on adderall.
>>
>>52536204
>Kahoot.it
what is this kiddie shit? underage b&?

RASPBERRY PIE CONFIRMED FOR KIDDIE TOY
>>
>>52536160
I think I'll just about manage to live with myself, but thanks for the concern.
>>
>>52536211
Jesus Christ, those variable names are fucking horrible.
>>
>>52536161
It's really, really not
>>
>>52536200
so they brought back the kek filter :/
>>
>>52536230
Well, yes.
It's meant to be a cheap computing platform for hobbyists and 3rd world kids learning to code.
>>
File: images.jpg (8 KB, 240x210) Image search: [Google]
images.jpg
8 KB, 240x210
guys, how do I make a game engine?
>>
>>52536211
why aren't you using the array module?
>>
>>52536161
.......... how about no. they're productive tools for *programmers* to use in collaboration with game designers and artists.
>>
>>52536211
feminine as fuck

10/10

>>52536252
2D or 3D?
>>
>>52536240
great argument.
>>
>>52536175
Gamemaker is not really a choice. It's like unity but worse.
Other than ue4? If you're developing for windows-only, XNA is a decent choice. MonoGame is similarly good, and it works on pretty much every system. The thing with these engines is that they're little more than graphics pipelines and you're going to have to do most of the legwork yourself- good if you're with a large team, bad if you're alone.
I'd recommend UE4 or Unity. Unity if you have less experience developing and/or don't have a large team.

>>52536200
>Software costs money if you use it to make money ?!?!?!? Preposterous!
the fuck? How do you think companies make money? Every decent engine on the planet does this. If you're releasing a commercial game with unity, just buy a license. Just because it's outside of my personal hobby budget doesn't mean that it's incredibly expensive.
>>
>>52536186
First page of results on google.
Why would I waste any more time than I already have pretending to care about finding reasons why a bad language is bad?
>>
>>52536252
That depends on a lot of things
>>
whats the most masculine language?
>>
>>52536252
If you have to ask...
>>
>>52536065
Javascript is a horrible, badly designed mess. There are way better languages out there you can do real functional programming on.

Why would you do functional programming in the first place is beyond my understanding, though.
>>
>>52536252
Write the main loop. Let some game dev user register things to the loop.
>>
>>52536278
ANSI C with inline ASM.
>>
>>52536269
it's not even worth whatever the license costs though and they rake in the dough from selling pre-fab assets to steam greenlight trolls and wannabe game dev manbabies
>>
>>52536278
Fortran
>>
>>52536278
verilog
>>
>>52536278
Forth
>>
>>52536278
C++
>>
>>52536264
yeah, guess so. I've been working in them for a while and they all just sort of feel like they're this layer of bullshit I have to wade through to get to actual programming.

>>52536265
2D

was on SDL for awhile. problem with a lot of these is they don't seem to have many good learning resources.
>>
>>52536252
int main()
{

init();

while(1){
update();
draw();
}

cleanup();

}


that'll be a million shekels pls
>>
File: descartes.jpg (151 KB, 817x1000) Image search: [Google]
descartes.jpg
151 KB, 817x1000
>>52536278
D
i.e. the D
ergo masculine
>>
>>52536278
C+=

It takes a real manly language to admit most languages are problematic.
>>
>>52536298
You clearly don't know jack shit. Inline assembly isn't specified anywhere in the C standard.

See, this is why /g/ is so full of shit. Stupid autistic neckbeards who'll claim they know ancient, dead languages only because they wrote a Hello World 5 years ago.
>>
>>52536200
Also
>enginebabbies
have fun writing an engine from the ground up and then eventually releasing a game that, even if it makes tens of thousands of dollars, will factor out to you making less than minimum wage over the length of the development cycle.
Sure, ideally we'd all be programming it from the ground up, but that shit takes too long. Don't need to reinvent the wheel.

>>52536302
>it's not even worth whatever the license costs though
75 bucks per month to give every person on your team your primary development software? Do you realize how cheap that is in the grand scheme of things? Compare that autodesk software. It's outside of my range as a solo developer, but that's not at all unreasonable.
>>
>>52536211
You're not saving the previous value of A[i+1]
>>
>>52536230

Kiddie toy maybe, but it's also a cheap solution to many real world problems and it's brutally effective in the right application
>>
>>52536310
VHDL is arguably more masculine than Varilog
>>
>>52536278
BASIC
its manliness can only be contained in all caps
>>
>>52536332
>You clearly don't know jack shit. Inline assembly isn't specified anywhere in the C standard.

Hence why he said "AND inline assembly". As in, in addition to ANSI C, also include inline assembly, because it is not included in "ANSI C"
>>
File: OpenGL-ES-2_0-Reference-card.png (2 MB, 1944x1320) Image search: [Google]
OpenGL-ES-2_0-Reference-card.png
2 MB, 1944x1320
>>52536317
use raw opengl m8 it's not that hard especially for 2D, just might look scary to a complete novice
>>
>>52536320

I did that in TI-basic
>>
>>52536340
Wiring your own circuits by hand is manlier than any HDL.
>>
>>52536320
"Most efficient game engine in history"
>>
So we all agree the most feminine language is Python?
>>
If Unity is good enough for you, use it.

Just don't project that onto everybody else, and don't be a fanboy. Accept that it's not a silver bullet, and don't recommend it without first ensuring that it's a good fit for the other person.
>>
>>52536352
>>
>>52536355
Yeah but that wasn't the question
>>
>>52536364
Most feminine language is JavaScript. Used by everyone, and spits out a nonsensical answer even when it should return an error.
>>
>>52536340
>inspired by a language named after a girl and a language named after a French philosopher that isn't Descartes
>manly
>>
>>52536384
literally this

>>52536364
python is more like a retarded male ADHD kid
>>
i'm trying to convert a sq; query like this into a grails criteria query

SELECT * FROM feature  INNER JOIN feature_relationship AS fr ON (feature.id = fr.child_feature_id) where feature.class = 'gene’;



i think maybe something like this

      def features = Feature.createCriteria() {
createAlias("parentFeatureRelationships", "fr")
eq("fr.childFeature", ???what goes here???)
eq('class', 'gene')
}


i dunno what to google for at this point
>>
What should I use for a simple web server on linux? It just accepts JSON and shits it into a database.
>>
>>52536375
Note that this applies for literally any tool.
>>
>>52536419
C
>>
>>52536421
but especially for unity because of how shit it is
>>
>>52536419
python with flask
>>
>>52536175
ue4, tesseract, ogre/irrlicht/darkplaces+cegui+openal+bullet, cryengine, id tech engines, etc.
>>
>>52536376
>>52536352

fuckin starred
>>
>>52535473

Can someone post the programming challenges, I'd like to work on some
>>
>>52536375
>>52536421
>>52536442
I just got a weird sense of deja vu.
>>
>>52536278
OCAML
C
A
M
L
>>
>>52536471
Here's a challenge:
Make a program that kills itself.

Than kill yourself.
>>
>>52536465
>cryengine, id tech engines,

fucking hell, m8
>>
>>52536497
>being this angry at the truth
>>
File: challenge.jpg (752 KB, 1920x1080) Image search: [Google]
challenge.jpg
752 KB, 1920x1080
>>52536471
>>
>>52536392

if it is named after a girl than that makes it more masculine

it's kind of a tradition in engineering. For example:

https://en.wikipedia.org/wiki/List_of_U.S._military_vessels_named_after_women
>>
>>52536266
If I were trying to argue with you, I'd argue with you
>>
>>52536471
Here's one my friend put together https://github.com/karan/Projects
>>
>>52536520
All of the Super Carriers are named after men
>>
File: Screenshot_2016-01-20-19-06-02.png (42 KB, 1080x1920) Image search: [Google]
Screenshot_2016-01-20-19-06-02.png
42 KB, 1080x1920
>>52535863

>can't compile programs on phone
Yeah, okay kid.
>>
File: no thanks.jpg (24 KB, 450x450) Image search: [Google]
no thanks.jpg
24 KB, 450x450
>>52536563
>--std=c11
>>
>>52536554

really it's just more fashionable to give anything that you are proud of a feminine name in engineering
>>
>>52536497
still miles better than the unity engine
>>
On a redesign of our startup's website... I just realized how easy is everything with angular js. Literally made a fully functioning reporting system with all the filters in an hour.
>>
>>52536580
pls not again
>>
>>52536554
that's kinda gay
>>
>>52536595
>js
>js
>js
get the fuck out
>>
>>52536610
It's very masculine: supercariers spew their load out from time to time after all.
>>
>>52536580
>not using C11

it's the current year.
>>
>>52536580
Stupid wincuck.
>>
>>52536620
I was saying the same thing, and I'm opposed to using JavaScript for backend development, but believe or not the front end game is dominated by JavaScript and its not gonna change
>>
>>52536563
I'm sure it can run vi as well with a REAL keyboard
>>
File: 1449052102476.gif (14 KB, 250x200) Image search: [Google]
1449052102476.gif
14 KB, 250x200
So I'm new to multithreading
Let's say I have two classes: A job manager, and a job. There are multiple threads of job running. When a job has an update to its data, it adds to a list in the job manager. Is this code thread-safe? if not, how could I make it so?
>>
>>52536738
>>>/tumblr/
>>
>>52536661

Actually, the termux version of vi is shit, even when you ssh into the phone. I have other editors on device.
>>
File: 1452978564755.gif (4 MB, 192x136) Image search: [Google]
1452978564755.gif
4 MB, 192x136
>>52536580
>there are people in current year that don't like c++11
>>
>>52536519
bring it
>>
>>52536298
>inline ASM
No. Inline code is a language's way of getting cucked.
>>
>>52536759
>++
>>
>>52536759
Are you aware that there is a C programming language completely independent from C++?
>>
>>52535533
Should've masturbated to 2D desu senpai.
>>
>>52536738
>When a job has an update to its data

Put a lock on this, unless only the job manager does this.

>it adds to a list in the job manager

Put a lock on this.
>>
>>52536594
have you used those engines?
>>
>>52536759
Holy fuck, sepplesfags are stupid.
>>
>>52536759
sauce of gif?
>>
>>52536823
Yes. Have you? (of course not, you're talking entirely out your anus and have been from the very beginning).
>>
>>52536827
my gf when i show er my cock 1st tiem ;) lov u bae
>>
>>52536738
what language?
>>
>>52536823
>porsche 911
>not as nice as koeniggsegg regera
>still miles better than the renault clio
>have you used those cars?
>>
>>52536409
>design SQL, the world's best language for querying relational data
>wrap it in some half-assed ORM
I've never understood this.
>>
>>52536738
How a job system works is that you have N worker threads running all the time. Each worker is either processing a job (which is basically just a thunk), or waiting for one. You schedule jobs with a shared queue, and retrieve the results asynchronously with a future.
Future<A> schedule(Thunk<A> thunk)
>>
>>52536838
really? what have you worked on?

all I ever hear is how difficult they are to use. probably why they aren't used for much.
>>
explain why Rust is bad without ad hominem
>>
>>52537005
It doesn't offer enough static verification ability over C++ to be worth the ecosystem refresh and practically esoteric lifetime DSL.
>>
>>52536827
Le_Lea, apparently.
>>
>>52537043
>and practically esoteric lifetime DSL.
less than 1% of all declarations need a lifetime annotation and the rest are inferred
>>
>>52537005

Bloated runtime environment. Can't make hello world without also linking against the threading and networking libraries...

Of course, that is not to say that the C++ and Ada standard libraries aren't just as fucking huge.
>>
Threadly reminder that you should not refer to act of programming as coding as it sounds improper
>>
>>52537074
>Bloated runtime environment. Can't make hello world without also linking against the threading and networking libraries...
shucks, guess that rules out running it on the PDP-8. Guess we'll have to settle for things like modern quadcore smartphones with 4gb of memory that everyone has had in their pockets for 5 years.
>>
>>52537043
Also, SJW shit.
>>
>>52536923
Main issue with cryengine is royalties, it's more brutal than with unity unless you get a full license, which is pretty expensive for small games. It's fairly easy to use as long as you're making an FPS, though. Haven't tried other types of games but I don't think it would be a good match. For making generic FPSs, it works great though. The tooling especially is phenomenal.

id tech engines are all extremely malleable and easy to work with, but they suck for open areas (or I suck at using them for open areas; I always get very poor performance there while cryengine performs a lot better). I made a shitty 3D platformer with id tech 4.
>>
>>52537087

What about running it on an Arduino, or an Onion Omega?

Although I doubt in such cases it would make sense to use the standard library... Speaking of which, why isn't no_std in stable yet?
>>
>>52537087
there is no excuse for needless bloat
>>
>>52537193
I believe the gnu herd developer(s) said this sometime in the early 90s too
>>
>>52537074
> Of course, that is not to say that the C++ and Ada standard libraries aren't just as fucking huge.
On any desktop or server system, the C++ standard library is going to be a shared library which is already installed (and most of what you use is probably already in RAM).

For static linking on an embedded system, C++ often turns out to be lighter than C.
>>
what do pajeets and javacucks have to learn in order to get a codemonkey job?
I'm asking in case I don't get the ideal financials functional programming job
>inb4 wagecuck
its only until I have enough to live by investments, cucks
>>
>>52537220
In particular, non-shit languages can do dead code elimination at the module level for coarse pruning.
>>
>>52537220
fun fact, glibc shared library is about 7x bigger than clang's libc++ and only slightly bigger than musl's libc
>>
>>52537259
>r than clang's libc++ and only slightly bigger than musl's libc
er, meant that clang's libc++ is only slightly bigger
not glibc
glibc is a fucking monster
>>
>>52537220

>On any Desktop or server system
Except for Windows. None of the VC++ DLLs are compatible with each other, MinGW's DLL isn't pre-installed, and in general, it is just wiser to static link everything to avoid DLL hell, or otherwise ship all of one's DLLs with the application, thus negating any space saving advantages. Since Rust does not have a DLL installed by default on all Windows computers (and Windows does not have a package manager for easy dependency resolution), it also has this problem.

C at least has the advantage of letting everyone link against msvcrt.DLL, despite how much Microsoft would not like people to do this.
>>
>>52537298
Microsoft purposely made it as shitty as possible to use non-.NET technology on windows to force everyone to embrace .NET.
>>
>>52537246
anyone?
>>
>>52537351
learn basic java, the rest they'll teach you on site probably
>>
>>52537351
enough to program a suicide bomber
>>
>>52537351
Learn how to shit in streets.
>>
>>52537397
that's pretty simple just make sure the street is designated
>>
Do you ever program to forget, /dpt/?
>>
>>52537408
You have to know how to use your hands and especially how not to use them, though.
>>
>>52537456
I program to forget the fact that you fags exist jk ily bby
>>
>>52537456
Sometimes I forget to program. Then I get fired. Fired up that is. Hahaha.
>>
does anyone have recommendations for picking up coffeescript? a potential employer uses it
>>
>>52536298
>AT&T syntax
>manly
o i am laffin
>>
>>52537502
Take the knife to your throat instead of bickering on about across the street or down the road and other nonsense.
>>
>>52536175
Why are you counting out UE4, I have been learning ue4 for a couple of month's it has great interaction and can go from low-high level depending on your goals and experience. If you want to make something more detailed and specific you can but it will be hard but you can also make something almost as detailed but not as specific as well rather easily.

I guess the bigest disavantage of ue4 is there are not many resources for c++ class coding, whereas there is a abundance of blueprint tutorials or wikis ect. Either way you can teach yourself a lot of things it just takes motivation and dedication, there are actually a few handfull of people who dedicate their time coding in c++ using unreal and post on the forums regularly, anyways just wanted to advise you not to just count out a engine because it is very flexible in my opinion.
>>
>>52537568
UE4 can make triple-A games so I don't know why someone would count it out. Maybe because it helps you too much. You know programmers feel insecure about that.
>>
>>52537627
>You know programmers feel insecure about that.
>saying this in the /dpt/
>>
>>52537630
Well it's true lmao even I am I admit
>>
>>52537610
you failed
>>
>>52537610
MODS MODS MODS MOOOODS!
>>
>>52537298
>DLL hell

It
Just
Works
>>
>>52537746
begone, she-boon lover
>>
>>52537779

why? i can programming too! just watch me poo not in the loo!
>>
File: nj.png (1 MB, 700x992) Image search: [Google]
nj.png
1 MB, 700x992
I wish /dpt/ had more tripfriends.

Can you all start using a trip?
>>
>>52537820

Anon, if you want to trip, go ahead and do it. Don't ask for others to do the same, however. We don't really need more tripfriends.
>>
File: dpt on a good day lol2.png (202 KB, 1189x273) Image search: [Google]
dpt on a good day lol2.png
202 KB, 1189x273
>>52537820
I could, but people already hate me when I post as anon.
Thread replies: 255
Thread images: 33

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.