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

/dpt/ - Daily Programming Thread

This is a blue board which means that it's for everybody (Safe For Work content only). If you see any adult content, please report it.

Thread replies: 325
Thread images: 34

File: 23242342344322.jpg (1MB, 821x1354px) Image search: [Google]
23242342344322.jpg
1MB, 821x1354px
Old thread at >>51606575

What are you working on, /g/?
>>
anime a shit
>>
Second for Egison
>>
File: GpnRJcZ.webm (826KB, 640x640px) Image search: [Google]
GpnRJcZ.webm
826KB, 640x640px
Ask your beloved programming literate anything.
>>
>>51613485
(PROGRAMMING-LITERATE?)
>>
File: 1413775162315.webm (3MB, 1372x756px) Image search: [Google]
1413775162315.webm
3MB, 1372x756px
>>
>>51613485
why are you proud of being illiterate?
>>
>>51613485
>there are people in this world that prefer cats to dogs
>>
>>51613554
>there are people in this world who prefer dirty, dependent, whinny, noisy dogs to strong, independent, clean, silent, fun-loving cats
>>
Is there a good OpenGL introduction video series? I don't even think I've fully understood the concept behind it.
>>
File: gore.jpg (95KB, 500x500px) Image search: [Google]
gore.jpg
95KB, 500x500px
>>51613554
>tell friend that his cat only sees him as a food resource and doesn't love him

>i dont care I just want something to pet

CAT OWNERS ARE KEKS

C U C K S
>>
>>51613576
what's not to understand
>>
>>51613586
i-is that a cat?
First time on /g/
Why are there so many shitskins asians?
>>
>>51613348
>What are you working on, /g/?
Pic related
>>
>>51613586
>tell friend that his dog only sees him as a food resource and doesn't love him

>I dont care I just want something to walk

DOG OWNERS ARE KEKS
C U C K S
>>
I'm going to read the C programming language, 2nd edition to learn C. what book should I read after that?
>>
>>51613617
>go in house
>dog goes apeshit acts like I've been dead for 20 years

>go in house
>cat doesn't even look at me

whatever u say catfriend :^)
>>
>>51613609
>shitskins asians?
During WW2, many restaurants served cat but labeled as rabbit (Its said that the taste is very same). If someone would offer me to taste cat, i would accept.
>>
>>51613617
>Stuff that never happened: the post
There can be no doubt about how genuinely dogs love their owners. My old dog ate like a fat fuck, but would hardly ever eat anything when he was on the house on his own.
>>
>>51613622
After K&R you shouldn't read anything, you should start programming.

Then, read the C standard.
>>
>>51613617
dog sees the owner as the alpha. Basically the same as a woman sees her man. So the love of a dog is comparable to the love of a woman.
t. woman-dog scientist
>>
>>51613622
What the fuck haha.

Never programmed before?
Are you in college or taking programming classes?
Read that book then go read Data structures,algorithms etc..learn a fully OOP language like Java to practice OOP principles etc...
Look over Comp. Eng or Comp .Sci college plans.
>>
>>51613622
k&r is shit. read c primer plus.
>>
File: e5vgb.png (599KB, 1025x710px) Image search: [Google]
e5vgb.png
599KB, 1025x710px
>>51613564
my dog leaves hair everywhere
loves walks, but sleeps a lot too
is deaf, which actually has cool upsides (hand signals to sit, come, etc, plus she isn't scared of thunder)
and of course, loves me unconditionally
even if I accidentally step on her toe, and she yelps
she still comes to me wanting a pat

dogs are the best.
>>
Cats are superior
Proof: Caturday, funny cat pictures, piano cat videos, cats everywhere
there's no dogday is there, checkmate dog lovers
>>
>>51613517
Are you still wasting your time on this garbage? Good god I swear I saw this a year ago.
>>
>>51613650
That makes sense Dr. Woman-dog.

gud to be loved by my waifu :^)
>>
>>51613669
but dogs have a whole meme
>>
>>51613669
>pet not on reddit
>this isn't a good thing

haha ok senpai
>>
>>51613634
That's only because the dog is so retarded that he sees the food as part of your body. Hence, if the body isn't there, the food isn't there either.
>>
>>51613586
How can you even tell the difference? If a dog/cat loves that you spend time with them and feed them is that not just love, or is it not good enough?

I have had 2 cats, one of them was pretty nonchalant and the other clearly missed me when I wasn't around. They're not pack animals so they don't exaggerate this stuff but it's there.

I'm not really sure why people choose one over the other, I haven't spent much time around dogs but I think they're cool too. I'd probably get a cat again, for sentimental reasons.
>>
Oi cunts, stop talking about programming in the Dog Petting Thread
>>
>>51613692
>what is doge
>>
>>51613695
The desperate defensive logic of cat owners everyone.
>>
>>51613690
cats have a whole website of memes http://www.lolcats.com/
checkmate once again dogfuckers

>>51613692
>>51613690
>>
File: mods-are-gay.png (52KB, 613x410px) Image search: [Google]
mods-are-gay.png
52KB, 613x410px
Full derailment after 3 posts

Why do I even bother coming to this board anymore?
>>
>>51613710
baby don't hurt me
don't hurt me
no more
>>
>>51613722

Furries also have websites. :^)
>>
>>51613722
Dogs have their own cryptocurrency
>>
>>51613738
furries usually dress as foxes, wolves and dogs
all dog-like creatures
checkmate again
>>
>>51613722
Those are not really memes but captioned pictures.

>>51613690
My neighbors just got a shiba, they were forced to give the dog a Japanese name (Japan want to preserve its culture at any cost).
>>
>>51613755
but I dress up as a bear when i le fuck ur mom XD
>>
>>51613763
>not having a wolf called laika
>>
I thought this thread was about programming
>>
>>51613774
dog v cat is programming
>>
>>51613749
who needs currency when people worship you?
https://en.m.wikipedia.org/wiki/Cats_in_ancient_Egypt

>>51613763
http://knowyourmeme.com/memes/grumpy-cat/photos
>>
>>51613755
Because dogs are more desirable. checkmate catfucker :^)
>>
>>51613789
https://en.wikipedia.org/wiki/Anubis
>>
>>51613793
desirable to fuck by mongoloid autists that's what

>>51613803
https://en.wikipedia.org/wiki/Bastet
>>
>>51613821
ur just mad cuz cats arent p enough to fuck xD
>>
File: a ruff victory.jpg (8KB, 173x292px) Image search: [Google]
a ruff victory.jpg
8KB, 173x292px
>>51613821
>>
>>51613789
tartard sauce was a meme but its now well forgotten contrary to doge

>>51613774
doge has its own programming language: http://pyos.github.io/dg/
>>
http://www.dog-lang.org/
>>
File: 1428859573377.webm (3MB, 752x288px) Image search: [Google]
1428859573377.webm
3MB, 752x288px
>>51613517
I remember this being the inspiration for starting this little desktop companion thing. Development stalled because I couldn't find a good abstraction to contain the complexity of adding new functionality, but recently I discovered QStateMachine and I rewrote it using that. It's a lot more manageable so I'd like to do more with it when I've got time/motivation.
>>
>>51613864
kill your self my man
>>
File: 1280px-Garfield_the_Cat.svg.png (145KB, 1280x764px) Image search: [Google]
1280px-Garfield_the_Cat.svg.png
145KB, 1280x764px
>>51613855
>>51613847
http://lolcode.org/
>>
>>51613864
quit posting programming in my dog thread
>>
>>51613875
2 > 1
checkmate garfield
>>
>>51613875
>esoteric language
dropped.
>>
File: a ruff victory.jpg (46KB, 500x500px) Image search: [Google]
a ruff victory.jpg
46KB, 500x500px
>>51613875
>>
>>51613864
You're more sad than the animalposters. At least their animals exist phisically and live.
>>
>>51613864
are you this alone ? why are you programming this ?
>>
>>51613660
k&r is a very well respected book and I've been told it's still very relevant.
>>
>>51613913
3dpd
>>
>>51613864
>I couldn't find a good abstraction to contain the complexity of adding new functionality
>vomiting_dog.jpg
>>
>>51613926
It's relevant if you're working on code straight from the 80's, otherwise it's garbage, just like dogs.
>>
>>51613951
>being a kekold

catold
>>
>>51613966
>being a coalburner

Dogged
>>
>owning any animal pets
>>
>>51613922
It's fun!

>>51613946
That's what happens when your project gets beyond 100 lines.
>>
>owning normie pets

badger masterrace reporting in :^) catfags and dogfags fucking kill yourselfs
>>
>>51613993
if you need more than 100 lines, something is wrong
>>
>>51614002
Enjoy your diseases!
>>
>>51614023
Enjoy that feline aids friend :^)
>>
>2011 + 2^2
>not owning a pet rock
enjoy poop scooping, faggots
>>
>>51606990
What programming language, and what are your interests? I might have one that fits your description.
>>
>>51614046
Sorry, I'm not a dogfag, my pet scoops after herself!
>>
>>51613993
>That's what happens when your project gets beyond 100 lines.
that's what happens when you spew useless jargon instead of actually learning how to program
>>
>>51614055
Egison, and making the Gibson.
>>
>>51614066
>having an animal shit in a box
>said box is typically in the kitchen

vomited
>>
>>51614089
>his pet doesn't know how to use the toilet!
>>
>>51614106
My fish did when I through him in it.
>>
>>51614076
"Abstraction" is useless jargon?
>>
This thread is cancer. We're supposed to be talking about programming, not pets.
>>
>>51614139
real abstraction doesn't take 100 lines
>>
>>51614142
dpt - daily pet thread
>>
>>51613517
very cute, desu senpai
>>
>>51614139
To dogfags, it is. They aren't very smart after all.
>>
>>51614142
Par for the course for generals. Just have to accept it.
>>
my anus itched, but i used my cat's claw to scratch it
good luck with that dogfags
>>
>>51613993
>That's what happens when your project gets beyond 100 lines.
OOP nigger
>>
>>51614157
dpt - DOG pet thread
>>
>>51614079
N-nvm... then..
>>
>>51614185
dpt - dog PUNT thread
>>
>shilling this hard
>>
best thread to date tbqh.
>>
What does /dpt/ think of mozart/oz?
>>
>>51614183
Qt kind of forces you into OOP unfortunately.
>>
>>51614200
dog boat thread

I like it
>>
>>51614219
For a dog name?
Not bad.
>>
>>51614219
>listening to mozart
>not beethoven

Fuck you!
>>
>>51614214
lgbtbqh
>>
File: a ruff victory.jpg (10KB, 189x267px) Image search: [Google]
a ruff victory.jpg
10KB, 189x267px
>>51614245
>>
>>51613586
>he has to rely on a pet he bought and keeps a prisoner for having someone "love" him

Wow dog owners are pathetic. I bet you let him fuck you in the ass as well. Enjoy walking your whiny gimp-wolf and pick up shit from the street five times a day. Cats are superior.
>>
>>51614285
What's the point of a pet at all then?

Might as well buy none and not pick up shit.
>>
Hello, /g/

I have Android classes and my teacher sucks hard.

Can you tell me any nice tutorial for Android about services, content providers and fragments?

Thanks in advance.
>>
>>51614310
I believe you're in the wrong thread.
This is /dog petting general/
>>
>>51614278
holy kek i can't stop laughing at this thread
>>
Fuck off with the petshit. You're all equally pathetic.

Go to /b/ and make a thread
>>
>>51614310
https://www.udacity.com/course/developing-android-apps--ud853
>>
>>51614278
https://www.youtube.com/watch?v=FTwWwVPdDEc
>>
File: 1442991161450.jpg (214KB, 444x467px) Image search: [Google]
1442991161450.jpg
214KB, 444x467px
Im everything dog pet general hates:
>code gaymes
>in java
>>
>>51614310
http://developer.android.com/reference/packages.html
>>
>>51614225
Why unfortunately ?
>>
>>51614306
>being so beta he can't make a pet love him unless it comes pre-brainwashed
Wow. Just wow.
>>
>>51614382
That's a BUCKwild reply.
>>
>>51613617

>Walking is bad

I believe you tat you genuinely feel that way, but still who the fuck would want some autistic animal that shits in a box?
>>
>>51614380
Because he fell for the "oop is bad" meme.
>>
>>51614382
>thinking you can get a cat to love you

catfags everyone
>>
>>51614394
>he says, while being the proud cu ck of an autistic animal that shits itself if he's not manually dragged along outside
>>
>>51614406
fucking this, cats are selfish bastards. A dog would stay by your grave every single day, they're that loyal.
>>
>>51613564

>I like emotionally distant animals that completely ignore me

literally autism
>>
>>51613554
>>51613564
>>51613586
>>51613617
I like both cats and dogs. you faggots should stop arguing, their personality traits depend a LOT on their race.
but I prefer cats: at least they aren't as retarded as some dogs.
>>
>>51614428

Left the dog in the house for a whole day and night once. He didn't piss or shit anywhere. True loyalty
>>
>>51614429
>fucking this, cats are genius bastards. A dog would stay by your grave every single day, they're that retarded.
>>
File: a ruff victory.jpg (26KB, 400x400px) Image search: [Google]
a ruff victory.jpg
26KB, 400x400px
>>51614430
I typed in autistic dog into google images. Got this. Pleasantly surprised.
>>
>>51614441
kek even the neutral person agrees that cats are superior
>>
>>51614447
stuffed dogs don't count senpai
>>
>>51614441
Black cats are the worst.
>>
>>51614452
>neutral
>thinks one side is superior

Do you know what neutral means? son
>>
>>51614441
>at least they aren't as retarded as some dogs
https://www.youtube.com/watch?v=faJx8ikHJAo

lol
>>
>>51614429
sure buddy, because that box is gonna empty itself right? I bet you enjoy your cat walking on your face with fucking shit paws.
Enjoy your giardia buddy...
>>
>>51614469
he's probably a dog shill trying to make cat owners look bad
>>
>>51614497
>catfag
>talking about shitpaws

I think you got the animals confused.
>>
>>51614473
https://www.youtube.com/watch?v=b1JRaGJpzc8
lol i can cherry pick too
>>
>>51613729
I thought it was stupid at first, but I'm now finding this entire thread funny as hell. also, reptiles of all kinds are the master race, they're the coolest pets ever.
>>
>>51614506
If dogs are so great, why is this a dog eat dog world? Dogs are cannibalistic, retarded savages! Checkmate, dogfuckers!
>>
>>51614380
It's nice to have a choice.
>>
>>51614538
>not eating other humans


shaking my head
>>
>>51614518

Are you really that autistic? Cats bury their shit, everyone knows that.
>>
File: a ruff victory.jpg (3MB, 5616x3744px) Image search: [Google]
a ruff victory.jpg
3MB, 5616x3744px
>>51614538
Because you don't survive by sitting on the back of a couch. You survive by straight up fuckin' a nigger up.
How many cats are used in war?
>>
>>51614524
this, top kek
the 1st one looks very stressed, though

>>51613586
forgot to mention: people eat dogs, too... willingly or not :)
>>
>>51614584
>risking your pet's life and treating it as a useless object
wow dog owners sure don't respect their pets, might as well own a horse while you're at it
>>
I'm allergic to dogs, but not to cats
1 - 0, fagdogs
>>
File: a ruff victory.jpg (102KB, 600x529px) Image search: [Google]
a ruff victory.jpg
102KB, 600x529px
>>51614600
Horses were used in war too.
Look at this fuckin' dog. you could ride him into glorious combat and win. Can you ride your cat? No, because you're fat and lazy just like your cat.
>>
>>51614600
that dog is very well trained. dogs are very useful for assisting humans in war, always have been.
>>
and most importantly: women rather fuck dogs than you guys :^)
>>
>>51614614
>implying me and my 52 cats are dumb enough to put ourselves in life-threatening situations like war
>>
>>51614600

Good luck with that fucking cat protecting you when you get robbed and they steal your previous figurines.
>>
>>51614627
More like, the dog is so retarded that it will eat a bullet if told to. That is, if she's not too busy eating her own tail.
>>
>>51614644
Same to your dog.
>dogfags so retarded they think dogs magically protect their owner regardless of race and training
>>
>>51614629
(^:
>>
>>51614638
The assault on my nostrils when I walk into your house would be worse than losing my dog to a bullet in Syria.
>>
>>51614638
>I wouldn't fight for my nation because I'm too much of a fat pussy

>>51614646
A dog can also do roles like tracking or as a sentry or a scout.
>>
>>51614668
>cat
>smell
You got the wrong pet there, dogtard.
>>
>>51614722
He was talking about you, catfag
>>
>>51614644
there's no mexicans or blacks in my neighborhood so i'm good

>>51614687
top kek, you keep fighting for our freedumbs soldier, don't forget america is the greatest country on earth and COD is the best game ;^)
>>
>>51614600
Well, a pet owner is necessarily treating the pet as an object, as it is something that is owned. It's not like the pet asked to be a pet. I like the doublethinking that makes the pet owners care for their pets and at the same time treat them as some sort of jesters in their twisted king's court. At least dog owners can utilize their dogs in ways that make the dogs feel happy and needed as a part of their pack, compared to cat owners whose cats are trophies in their houses, doomed to go mad from the lack of stimulus and the constant presence of omnivorous predators ten times their size.
>>
157 posts about dogs. Best thread.
Need more /dog petting general/ pls.
>>
>>51614747
liberal vaginas like you belong on reddit, along with the other cat owners.
>>
>>51614779
that's the spirit soldier, let's kill all those ayrabs and take our country back! yeehaw!
>>
>>51614749
I have yet to see a cat go mad and give more than a single shit
>>
>>51614799
"..he said, whilst in the safety of his mothers basement.

>>51614808
Bathe one. Or even hold your hand over the bed while the little shit is there. Enjoy shitclaws in your arm.
>>
>>51613622
H&S
>>
>>51614827
why are you talking about programming? this is the /dog petting general/
>>
File: 1448864929558.jpg (31KB, 328x351px) Image search: [Google]
1448864929558.jpg
31KB, 328x351px
I recovered a lot of pictures and need a way to find the n00ds from the crap. I was thinking of something like Tinder but for local images. Is there such a thing? Too lazy to program it but I will if I have to, these could be quality noods
>>
>>51614867
She looks suspiciously underage, and she doesn't have a dog. Please leave.
>>
>>51614825
>I put a gun to someone's face and they tried to kill me! Why am I the one in prison?
>>
>>51614892
More like
>I was sleeping and rolled over and the little faggot decided "playing" is the equivalent of slashing my arm up.
>>
>>51614909
>I'm telling you officer, I was just playing with the loaded gun!
>>
>>51614951
You're really reaching, anon.
Like a cat.
>>
>>51614961
Better reaching than using the dedicated shitting street like you, rajeesh and dog!
>>
>>51614986
We don't shit on the ground in Canada. My warrior of a dog pulls my sled. Your cat touches its precious paw to the snow and runs to hide inside the couch for 3 days.
>>
back to programming
how do I make my own virtual cat? a virtual dog is easy, cats are more intelligent and sociable between one each other, so more difficult to imitate
>>
>>51615061
Slap your dick on the keyboard for a few minutes.
Back to dogs now.
>>
>>51613633
sorry i'm all out of cats.
but i got a nice cock for you, your mom would recommend.
>>
>>51615061
this is the /dog petting general/, go talk about programming in the programming general.
>>
>posting dogs
I am okay with this

Also, going to make a basic calculator using an Arduino for class. Then I need to think of another easy project to do on the Arduino before Friday.
>>
File: 1433365699021.jpg (92KB, 1024x768px) Image search: [Google]
1433365699021.jpg
92KB, 1024x768px
>>51613348
Working on an arduino powered smartphone controlled robot and I can't quite seem to get the arduino program working.

The controls are based on a 10 digit number which gets broken down into single digits and loaded into an array.

Before I started making it, I tested it out first and made this: http://pastebin.com/fWtc3H7u

And when it came to implementing it in the arduino sketch I can't get it to work. Here's what I've got so far for the sketch: http://pastebin.com/byjvvmCZ

The problems are: The first for loop shits the bed when the condition has more than one digit in it and causes it to endlessly loop and my split func doesn't work properly, because the bluetooth_input variable doesn't seem to hold what was put into it. Due to the limit of doubles?

Anybody know what might be causing this?
I don't really know what I'm doing.
>>
>>51615223
Animatronic Dog?
>>
>>51615255
Just noticed I forgot to add fmod back into the arduino sketch on line 111, seeing as modulo doesn't work with doubles.
>>
>>51615263
Seems doable
>>
What the hell is going on and when did this become dog general?
>>
>>51615354
/dpt/ - Dog Petting General
/cpt/ is not Cat Petting General though, it's Cock Petting Tutorials, because only faggots own cats.
>>
>>51615255
>that pic
cannot unsee
what kind of sick fuck let a kid do that? the kid will be traumatized for life when he sees and understands what the dog was doing...
>>
>>51615391
Didn't know General starts with t
>>
>>51615401
>sexual contact is intrinsically traumatizing
leftist detected
>>
>>51615401
Oy vey, bad goy.
Beastiality is natural, it occurs in nature just like homosexuality.
>>
>>51615409
I'm retarded.
Dog Petting Thread general I meant.
>>
>>51615423
>>51615438
>taking a pic of a dog making sexual contact with a kid (probably his/her own kid) is not the work of a sick person
and this is the problem with lunatic homosexuals. it's not a joke that some homos are seriously fucked up
>>
See kids, this is why we post anime and not bestiality shit.
Anime doesn't derail threads.
>>
>>51615496
>go to a friend's house
>the dog humps my leg once
>this isn't funny at all
>I'm now traumatized for life
>I sue his ass off and have the dog put to sleep
Just as God intended.
>>
>>51615546
or just upset the dog and have him bite you. Then have the dog euthanized.
>>
>>51615546
are you retarded? there is a difference between YOU and a KID
are you trying to justify your mental problems or something? I assume you, and everyone in 4chan, is an adult. I don't care if you let dogs rape you or something. but that pic is just NOT the same thing.
>>
I use notepad++ on windows for doing simple Java programs

I'm looking for an alternative in Linux,but I want something whit the same features, specially functions and words auto completion.

Any recommendations?
>>
>>51615546
>Just as God intended.
heretics were burned for much less in the past.
>>
What's the fastest way for me to learn how to use a database with Python?
>>
>>51615638
get a dog
>>
>>51615668
this. you will have a ruff victory.
>>
>>51615624
>auto-completion
literally one of the worst features ever to be introduced to programming
>>
>>51615717
If you really can't be arsed to learn the standard library in your particular language, it's a godsend.
>>
>>51615739
If you really can't be arsed to learn the standard library in your particular language, you should stop programming
>>
>>51615717
there is nothing wrong with auto-completion it's literally one of the best text-editing tools in existence
>>
>>51615755
dubs wasted on a self-evident truth

but checked
>>
File: ruff victory.jpg (65KB, 500x368px) Image search: [Google]
ruff victory.jpg
65KB, 500x368px
Please, keep it programming related.
>>
File: 1425000777283.jpg (140KB, 720x960px) Image search: [Google]
1425000777283.jpg
140KB, 720x960px
>>51615739
>plug-and-chug
>programming
choose one
>>
>>51615833
why bother? we are at the last 100 posts till we hit bump limit.
>>
How would someone get into programming?

I know absolutely zero about programming and I'd like to learn to make a career out of it.

Is there anything I should know? Is there any equipment I need to have?

I'm housebound NEET and this seems like a good start to becoming independent as I already enjoy using computers, I'm far from an expert but my friends come to me with their computer issues and I fix them.

Is this a hard spot to dive into? Should I learn something like Web development first, then once I've mastered that move onto learning programming?

Maybe most importantly, I'm housebound, would that immediately cut me off from becoming a programmer?
>>
>>51615878
Pictures of dogs programming please.
>>
>>51615883
Housebound?
Perfect opportunity for a ruff victory dog.
>>
>>51615883
The absolute worst way to start programming is by talking to programmers. They're inherently shitty people who will jump at the chance to brainwash and indoctrinate you into the "right" way to do anything.
>>
>>51613610
is that nerdtree you use for tabs?
>>
>>51615883
https://docs.oracle.com/javase/tutorial/

you'll be fine

just stay away from:
>python
>haskell
>lisp
>javascript
>php
and some other ones but those are the worst
>>
Is this recursion /dpt/?
def sum_list(list,accum)

if list.empty?

return accum

else

accum += list[0]

list = list[1..list.length-1]

return sum_list(list,accum)

end

end


puts sum_list([1,2,3],0)
>>
Dogs are deprecated as fuck. Time sink pets that need washing, grooming, walking, and personal shit sessions
>>
>>51615934
(recursivep code)
=> t
>>
>>51615922
Do not listen to to this guy, he is literally cancer
>>
File: 1447014909231.jpg (165KB, 921x800px) Image search: [Google]
1447014909231.jpg
165KB, 921x800px
Anyone good with Java unit tests?
I need some help
>>
File: 20150823_141907.jpg (349KB, 1440x1080px) Image search: [Google]
20150823_141907.jpg
349KB, 1440x1080px
>>51615896
I have a puppy, his name is Abe.

>>51615902
Oh god, then who do I talk to?

>>51615922
I hear python talked about a lot, not that I'd know if it's any good or not though, I don't even know what actually makes a language good. Thanks though, anon!
>>
>>51615979
dumb frogposter
>>
>>51615965
stop
>>
>>51615986
https://en.wikipedia.org/wiki/Duck_typing#Criticism
>>
>>51615986
>Oh god, then who do I talk to?
whatever you do: don't talk to g.
>>
>>51616021
Talk to books and papers on programming
>>
File: 1448745286193-2.jpg (83KB, 768x1024px) Image search: [Google]
1448745286193-2.jpg
83KB, 768x1024px
>>51615883
You want a career? Learn C++, and then learn Python. As far as I can tell, this is the most /g/ approved way to not be a shithead and also make money.
>>
hi guys
I know python, scheme from sicp, learning java atm, which really feels different from func. prog.
planning to cover algorithms soon after, which should be done in 4-5 months
am i close to being employable, or do i have to learn the some C-s and go learn how to do cpus, kernels etc. before I start applying
>>
Anyone here knows JUnit?
Why do i need a Runner class when the tests can run fine without it?
>>
>>51616115
i mean i should be done with algos and java 4-5 months from now
should i applying then, or learn more and then try
>>
public String hiddenWord() {
String hidden_word = "";
// program here the functionality for building the hidden word
int index = 0;
while (index < this.word.length()){
char lett;
lett = this.word.charAt(index);
String lettString = "" + lett;
if (this.guessedLetters.contains("" + lett))
{
hidden_word = hidden_word + lett;
}else{
hidden_word = hidden_word + "_";
}

index++;
}

return hidden_word;
}


basically I want too:
- create the hidden word by interating through this.word letter by letter
- if the letter in turn is within the guessed words, put it in to the hidden word
-if the letter is not among guessed, replace it with _ in the hidden word
-return the hidden word at the end

Why isn't this working, I feel i'm doing everything correctly, instead i'm getting just pure underscores for the hidden_word output.
i've even tried using indexOf instead of contains and making it >0 if you know what I mean.
>>
>>51616165
ignore the lettString variable, I forgot to comment it out.
>>
Is Ruby a toy language? I've been wanting to get into it but don't really see a reason since I know Python.
>>
does anyone understand how to build gui's in c++.
Like actually understand instead of copying a template. Im not asking for instruction, Im trying to teach myself how to make a gui and wanted to know if I should actually be concerned with the basics, or if I should just look into exercises and not touch the basic template.
>>
>>51616115
you can be pretty retarded and still get a job if you're persistent enough with the job applications. ideally you should have a good grasp of at least one programming language and have experience in developing applications either on your own or in groups like on sjwhub
>>
>>51616208
Qt.
>>
>>51616215
>go to Qt's website
>click on download button
>its an installer exe
Fuck.
>find the source code download button
>its an installer exe
Dropped.
>>
File: 1344786035227.png (222KB, 500x323px) Image search: [Google]
1344786035227.png
222KB, 500x323px
>Assignment due in 3 days
>Still have no idea how to code Assembly properly
>>
>>51616250
engineering? what microcontroller you guys using?
>>
What happened to the dog petting thread?
>>
>>51616215
I feel like win32 is preferable if youre on windows
>>
>>51616115
Interview question: Build a binary tree of strings in your strongest programming language. Write methods to insert a new string into the tree, and search for a string already in the tree.

Then write a method to invert the binary tree, i.e. the left branch becomes the right branch, the left branch's left leaf becomes the left branch's right leaf, etc., all the way down both sides of the tree.

Grading: If you cannot do this in 30 minutes, you will not be hired. If you have to google the definition of a binary tree, your score will be reduced 7/10. If you google any part of the implementation, you will not be hired.

Post your results when you are finished. The timer starts immediately.
>>
>>51616165
please respond: java related question.
>>
File: ruff victory.jpg (58KB, 620x465px) Image search: [Google]
ruff victory.jpg
58KB, 620x465px
>>51616309
This isn't not /dog petting thread/ related.
>>
>>51616299
Wait, just binary tree. So like I dont have to make the tree even
>insert everything as a list but say its all going on the left branch
Would it really not be a bst. Also do you get access to the internet when doing these things.
I dont fully remember how to do this myself. Well I could probably get insert pretty quickly but the full implementation of a tree would take a while to recreate.
>>
>>51616261
I'm in Comp Sci and this stuff makes minimal sense to me. I don't know what you mean by microcontroller, but we're using a custom made computer (programmed in C) we designed in class over the course of the semester.
>>
You _could_ use Win32, but that's been obsolete for years. Better use https://en.wikipedia.org/wiki/Qt_%28software%29
>>
>>51616372
So what you're saying is you build CPU's and solder them?
>>
>>51616385
See
>>51616248
>>
>>51616389
We did it on Breadboards but most of it was just theory and done in C
>>
>>51616389
I think he's saying they wrote a cpu simulator.....
probably for a toy arch designed to teach cpus like lc-3
>>
I'm probably being stupid right now, but is it possible to turn an array into a circularly linked array where the final element is a pointer to the first one?
>>
>>51616165
>>51616189
nevermind, turns out one of my other methods were done incorrectly and basically guessedLetters did not contain all the guessed letter.
>>
File: 1369446960901.png (20KB, 256x310px) Image search: [Google]
1369446960901.png
20KB, 256x310px
>>51616165
>hidden_word = hidden_word + lett;
>hidden_word = hidden_word + "_";
>>
>>51616492
array[index] -> array[index % length]
>>
>>51615902
If you avoid the OO crowd (javadesis and seppleskids) and avoid the functional crowd (mainly just haskellers are the problem) then there's a host of people who are usually quite helpful.
>>
>>51616504
so what's the proper way of turning a char into a string in Java?
>>
>>51616461
>>51616488
>>
>>51616515
>C++ is an OO language
triggered
>>
>>51616191
Honestly it's one toy or another toy. If you know pythong there is really no reason to learn ruby unless you are doing rails. If you know ruby there is no reason to learn python unless you are doing data science
>>
Why would anyone learn Python over Java?
>>
>>51616549
It's amazing how many people miraculously never use OO in sepples whenever this topic comes up, and yet whenever people need help in sepples the answers are always OO-centric.

C++ fanatics are the biggest hypocrites in programming.
>>
>>51616532
Java strings are immutable. Every time you do that, you have to reallocate and copy the string over, which is ridiculously inefficient.
I'm no Javafag, but there is some other class for constructing strings much more efficiently, but I don't remember what it's called.
>>
>>51616561
Why would anyone learn Python or Java?
>>
>>51616542
I'm familiar with the meme, anon :^)
>>
>>51615955
this
>>
>>51616569
Oh ok, so C and Haskell are object oriented languages because they support object oriented programming
>>
>>51616592
>>51615955
Confirmed for shitpaw loving catfags.
Get out of my /dog petting thread/.
>>
>>51616561
>>51616573
Two completely different languages with completely differing paradigms. Java should be learned for things that Java is made for and python should be used for things python was made for?

Or are you little buddies just looking for a nice fizz buzz? (^:
>>
>>51616603
>shitpaw
I never really considered the levels of funposting possible with pets before, since the objectively best situation is owning a cat while having a friend with a dog. Is /an/ as fun as other boards? I always assumed it was full of normies.
>>
File: diagram.jpg (30KB, 618x800px) Image search: [Google]
diagram.jpg
30KB, 618x800px
Struggling to come up with a decent architecture for my rhythm game server. I have a rough idea, but I want to refine it before actually implementing it. The main problem is notifying clients from within the model.
I want players to create a lobby and invite other players in the lobby. The owner decides what beatmap to play. Once that's set, all players move to the game and play the beatmap until it ends. Rinse and repeat. Also the player is able to chat with other players in the group, but I consider that a feature.
Writing all individual modules isn't the problem, it's linking them all together without creating a tangled mess. I need the following: server, client, reader (reading raw input from client), writer (writing raw output to client), controller and model.
I'll be using Go, TCP/IP and JSON.
>>
>>51616532
Javababby here.
String s = String.valueof('c');
>>
>>51613864
That's cute
>>
>>51616641
This thread has seriously made my shift just fly by today, it's great. I've never been to /an/ but I would imagine it's a barren wasteland.
>>
File: C LI K.jpg (82KB, 444x445px) Image search: [Google]
C LI K.jpg
82KB, 444x445px
>>51613864
>wasting time on useless "desktop companions" when you could be working on vr companions instead
>>
>>51616641
Honestly this desu senpai.

Cats are little maintenance, fill a bowl and clean its shitter monthly. If you treat the animal properly it will love and respect you

Dogs are sub 15 iq brutes that require hours of effort, training, cleaning, grooming etc. But they are nice to interact with from time to time, just don't waste your time with owning them.
>>
Guys, are there any good alternatives to Java and C#? I don't want to develop using a language made by Microsoft and Java is just...no
>>
>>51616641
>>51616685
I didn't realise this thread existed

Surprise it's not infested with furries and mlp
>>
>>51616703
C++
D
>>
>>51616703
If your looking for strictly oop laguages

sepples
ruby
python
>>
>>51616703
What's wrong with the language originally being made by Microsoft if it's open-source and cross-platform now?
>>
>>51616703
those two languages will make you the most money, guaranteed.
>>
>>51616744
this

>>51616703
https://github.com/Microsoft/dotnet

C# is everything that Java is, but better.
>>
>python
>c++
>java
>racket
>autohotkey
Am I job ready. Considering learning haskell in my free time but if theres a different language that would help then Id learn that first.
>>
>>51616685
>>>/an/2008175
welp now I know what board to start lurking next. current cycle is to get bored with /g/, go to /pol/, get bored with /pol/, go to /sci/, get bored with /sci/, go to /v/, get bored with /v/, go back to /g/. Now I can inject some petposting inbetween.

>been here for 7 years
>still haven't been to every board
>>
>>51616836
You are pretty much all set but learn some web stuff just in case
>>
>>51616817
Ask any Java developer and he'll tell you C# is much better.
>>
>>51616817
Lol,sure buddy.
Last time i checked,at least in my country Java jobs were like 10x more and much better payed.
>inb4 thats cause of legacy enterprise apps.
c# will turn legacy before Java by at least a decade.
>>
Still requesting help from someone who knows about assembly. My current problem is
>input 1
>stored as 31 in AC
>subtract I 30
>somehow becomes negative
My theory is that this happens because my Integer 30 is in decimal but 31 is in hexadecimal but I have no idea how to convert to hex. I'm thinking it should be 1D? (Since 30/16 = 1R14 and 14 in hex is D)
>>
>>51616872
>C# will turn legacy before Java by at least a decade

Hahaha riiight

Both are growing at significant speeds it's just that a lot of companies are switching from Java to C#

Of course this wont kill Java because businesses have invested many years on shitty java code bases, so yes it is because of legacy enterprise apps.
>>
>>51616872
If you value your mental health you will not choose to work with Java
>>
>>51616858
When not run by charlatans and retards, inspired new languages generally do improve on old ones. Which is why scheme is better than lisp; why C# is better than Java (it took MS several attempts but they finally managed to make something people like); why ocaml is better than SML; and so on.

Unfortunately it also explains why clojure is not better than lisp, why python and ruby are shit, and why C++ is garbage.
>>
File: fuck fuck fuck.png (522KB, 500x737px) Image search: [Google]
fuck fuck fuck.png
522KB, 500x737px
I had a coding interview today and I was already exhausted and I fucked up the simplest questions senpai, I fucking ruined it, fuck my life

Why am I so worthless
>>
File: andrew wyr.png (35KB, 2400x1170px) Image search: [Google]
andrew wyr.png
35KB, 2400x1170px
A shitty 38 txt to image encryption
Python
>>
>>51616933
What kind of questions were you asked?
>>
>>51616933
What were the questions? Why the would you be exhausted at an interview. Learn to get some sleep child
>>
>>51616872
>defending java because it was the first language you learned
>>
>>51616668
Would the entity component system be my lord and savior?
>>
>>51616299
tried, couldn't do it, wrote an ordered list implementation, cuz didn't want to google

but as i said, i won't be applying before algos, which also includes data structures
>>
>>51616999
ecs
>>>/trash/
>>
>>51617013
Name a better alternative.
                                                                                                                           Protip: you can't because of my trips
>>
>>51616933
>>51616933
ghjghjghjghj
>>
>>51616925
>this is what c# fags believe
how can enterprise apps written in Java be legacy when the vast amount of enterprise apps are written in Java right at THIS moment?
>>51616926
why not?
I am still a beginner (2 years of coding experience) but i've done C++ and i would have wasted my time remembering how to make a window or important classes/functions whereas in Java everything is standardized and the IDE are god tier too.
>>
I have a c++ question for my homework desu.
so i have a class that holds primitive attributes (student) and another class with its own primitives and a dynamic array of class student as an attribute aswell (roster)
so i have to overload the square bracket operator in roster to for the dynamic array which is all fine and dandy,
but when i make an array of class roster in main and try to access a member function in the dynamic array i get a seg fault. im sure its the square bracket operator causing this shit. what do
Student& Roster ::  operator[](int i)
{
while(i <0 || i>capacity)
{
cout << "error, invalid number. try again";
cin >> i;
}
return *students[i];
}

>>
>>51617062
i > capacity
should be
i >= capacity

assuming you allow 0

also, why are you using signed ints if you're blocking 0s?
>>
>>51617085
blocking <0s*
>>
>>51616673
Thanks
>>
>>51616969
Just two. The first was to take an integer and swap each pair of bits. I knew there was a good bitwise solution but mine was just to loop through each pair and set the output bits, i.e.

int swap_bits(int n) {
int ret = 0;

for (int i = 0; i < sizeof(n) * CHAR_BIT; i += 2) {
int even = (n >> i) & 1;
int odd = (n >> (i + 1)) & 1;

ret = ret & (even << i + 1);
ret = ret & (odd << i);
}

return ret;
}


The elegant solution involved &ing n with an alternating bit pattern for the odd and even bits.

The second one was to rotate a linked list by n elements (bringing elements from the tail to the head). My first solution involved creating a new linked list and appending the elements of the original list to the head (i.e. creating a reversed version of the original list), then push the head of the list onto the original list n times, then iterate down the list a final time and cut off the old tail at the appropriate place. The interview stopped me here and gave me a hint, which was to iterate down the list with a follower pointer n places behind the leader pointer, and when the leader point reached the end of the tail, set the last element's next node to be the head of the list, and set the follower element's next node to be null.

Yeah, I know I'm an idiot.

>>51616976
I had classes all day. They're in a different time zone, so it's later in the evening here.
>>
>>51617035
Clearly you don't work in enterprise

>I am still a beginner (2 years of coding experience)

Speaks for itself you ignorant twat
>>
>>51617136
I love how interview questions are never relevant to industry

One time my interview question was to write an application that determines if a string was a palindrome (but there was a lot more that they were looking for)
>>
>>51616248
>installer exe
it probably has a gzipped file, which you could easily decompress with winrar, 7zip or something.
>>
>>51617085
because im a fucking pleb asking /g/ to help with my homework
>>
>>51617220
you don't check for palindromes on a daily basis?

looks like someone stores twice as much data as they should
>>
Any guy here knows JUnit?
>>
>>51617263
I know what you're suggesting and it sounds like a really bad idea.
>>
>>51617263
I never said that question was related to industry at all, in fact I was just offering one of the shitty unrelated interview questions that I got. I think you need to go take a bath and relax (((^:
>>
>>51617267
Everyone, that works with Java, should know JUnit and Java is a common language.
>>
I'm trying to do this in C#.

Say I have a library, Foo, and I want to make it so any methods called, such as Foo.FizzBuzz, ends up instead calling a different library, Bar, and its method Bar.BuzzFizz. How would I go about doing this sort of binding? I'm trying to transition code from one DLL to another without making the users have to change their code
>>
NEW THREAD

>>51617301
>>
>>51617291
Well,if anyone here knows JUnit whats the point of Test Runners?My test run fine without it.
>>
>>51617267
Assembly guy here, still looking for help. I know a bit about JUnit but I'm sure I'm doing something wrong. I basically just make methods with the @test (I think that's the one I use) above the method, do a test case, and finish with an assert equals for the result and what I expected.
>>
>>51617329
this is what i do.
But now on this tutorial they use Test Runner and idk whats the point.
>>
>>51617324
You don't need it when you're the only developer on the team and don't use build servers or such. Runners are a thing when you start to automate your tests and builds. You also don't need a test suite per se, only cases, but it's a nice thing to have when you have a shitton of test cases.
>>
>>51617476
I have for an interview to write a method that does a certain thing and then unit test it.
I've done the method but how do i proceed unit testing?
Do i use Junit 3 or 4?
I just make a test case and put all the possible unit tests inside with the asserts?I know i should have followed TDD and done the unit tests while i was working but i am new in Unit Testing .

For example ,if i receive a null string i put to throw a NullPointer or whatever Runtime exception it is and do the unit test to prove that the nullpointer exception is thrown.
Or check if my string received follows the format of the problem and if it should throw invalidFormatexception or something like that?
>>
Is there a way to upload video files to somewhere (like a pomf clone with a link shortener) in Python?
>>
>>51617808
Yes
>>
>>51617808
No
Thread posts: 325
Thread images: 34


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

I'm aware that Imgur.com will stop allowing adult images since 15th of May. I'm taking actions to backup as much data as possible.
Read more on this topic here - https://archived.moe/talk/thread/1694/


If you need a post removed click on it's [Report] button and follow the instruction.
DMCA Content Takedown via dmca.com
All images are hosted on imgur.com.
If you like this website please support us by donating with Bitcoins at 16mKtbZiwW52BLkibtCr8jUg2KVUMTxVQ5
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.
This is a 4chan archive - all of the content originated from that site.
This means that RandomArchive shows their content, archived.
If you need information for a Poster - contact them.