/dpt/ - Daily Programming Thread

What are you working on, Sup Forums?

Old thread:

Other urls found in this thread:

mazonka.com/shared/Straustrup4th.pdf
learnxinyminutes.com/docs/c/
learnxinyminutes.com/docs/csharp/
learnxinyminutes.com/docs/c /
github.com/ddobrev/QtSharp
github.com/dlang/dmd/blob/master/samples/sieve.d
3e.org/dmd/cv.pdf
myredditvideos.com/
twitter.com/NSFWRedditImage

where is a place I can learn C,C# and C++?
codeacademy has none of them and I don't know where to start

>Manually managing blocks of memory in C is like juggling bars of soap in a prison shower: It's all fun and games until you forget about one of them.

VB.net is easier to start it

...

Websocket server in C using libwebsockets. thinking about P2P file transfer and things like doodling together

but that's a shop user
I'm talking about some tutorial or guide,like codeacademy does.
I learned Javascript and HTML through codeacademy but I don't know how to do C,C#,C++ or where even to start in them

Anyone mind helping me fix this? C, reads stdin string and puts into BST

It just replaces all the nodes with the last inputted string, or something like that

/* Reads stdin one line at a time when input filename not provided*/
char *inName = NULL;
struct Node *root = NULL;
char sentence[100];
char *line = (char*) malloc (100);

if (inName == NULL) {
printf("\nEnter one line at a time:\n");

if (root == NULL) {
fflush(stdout);
fgets(sentence, 100, stdin);
strcpy(line, sentence);
root = insert(root, line, cflag);
sentence[0] = '\0';
free(line);
}

fflush(stdout);
sentence[0] = '\0';
while (strcmp(sentence, "\n") != 0) {
line = (char*) malloc (101);
sentence[0] = '\0';
fgets(sentence, 100, stdin);
if (strcmp(sentence, "\n") != 0) {
strcpy(line, sentence);
root = insert(root, line, cflag);
free(line);
}
}
}

that's not even a function

Try a beginner project and just start coding

captcha: road profession

>just code bro

but where?

For C, read the latest edition of C Primer Plus.
For C++, read this:
mazonka.com/shared/Straustrup4th.pdf
For C#, MSDN documentation should be sufficient.

VB.NET is dead desu. Didn't even get ported to .NET Core before F#.

i know, its happening under my main. I'm just trying to get the logic right, but i think when im doing root=insert(...) its not giving me what i want, so when i go and try to print the inorder(root) its screwed

>Straustrup

download the free version of visual studio and google a simple project

Sheesh, HOW often!
learnxinyminutes.com/docs/c/
learnxinyminutes.com/docs/csharp/
learnxinyminutes.com/docs/c /

well, the call for the recursive function should advance in the tree, that it, typically something like
recursive_func(node *root) {
while (root->next != NULL) {
recursive_func(root->next)
}
}


and i think you aren't moving in the tree, dunno

I'm aware that his name is misspelled, probably to keep the file from being indexed by search engines.

>codeacademy has none of them and I don't know where to start
..
>the internet has only codeacademy and Sup Forums
When I was young I went to the local library and grabbed a C book. Tried that? Apparently there is *nothing online* when you search for "c/c++/c# tutorial"..

Any sufficiently well-documented lisp program contains an ML program in its comments.

What compsci math book would be great ? I've found a MIT pdf about computer science math.

#include

Concrete mathematics

#include

>tfw I thought C# was called "C-hash"
>tfw no one corrected me

Do you make free software, /dpt/?

>no one corrected me
cause you have no friends :(

Should have watched more anime.

>tfw I hear someone say ess-que-ell

I wanted to tell you but you sound like such a faggot even thinking about you saying "octothorpe" makes me cringe.

>these jobs that have vague task descriptions that make me not sure if I would be able to do them or not
I can code, but I don't know if I can do what they need

>file extension .cs
>I wonder how this should be pronounced...

does anyone correct u when u call dicks delicious?

He has Sup Forums tho.
ess-que-ell > see-quel

Every single person I work with calls it Ess Queue Ell, they probably don't even understand the wordplay in the name PostGreSQL!!!

CuteSharp.

found the redditor
you're fucked in both scenarios:
1) you watch anime d*bb*d
2) you don't watch it

All true.
Why would anyone correct a true statement?

>anime d*bb*d

Is there a minimum frequency to use for an SPI interface? I need a DAC, and I'll only need to set it less than once a second, so 100hz is literally the highest I would possibly go, bit-banging the data I need to set the output.

I know SPI itself has a "minimum" frequency of 1MHz or something, but I since I don't need ANYWHERE near that, I want to know if I could drive it slow. I'd expect my chip to only respond on the clock cycles (there'd be only the one clock, no data would be sent back, etc) but I'm trying to find any resource on running the interface slow and I can't find any.

I'll be asking this on DIY as well

The Big O and FLCL had good dubs IMO

No, that would be how you pronounce this:
github.com/ddobrev/QtSharp

Yes

i almost vomited myself when writing that.
Please leave this website and never ever say anything like that.

...

N-no bully

I started learning D but seeing D is just as unsafe as C++ I am moving to Rust.

Rust is just as unsafe as C++ if you use the unsafe keyword (necessary for some things)

How
You can easily write safe D

>tfw you fall for the Rust meme

p-please show me your D

Only inside the unsafe blocks.

l-lewd

Where's the fun in programming when everything is inherently safe?
also
An inherently safe chainsaw is entirely useless.

Do I still have to write shit like 'type a = Integer' at the beginning of every file if I'm using the UnicodeSyntax extension?

>my D
here
import std.conv;
import std.stdio;
import std.range;

void main(string[] args)
{
immutable max = (1 < args.length)
? args[1].to!size_t
: 0x4000;
size_t count = 1; // we have 2.
// flags[i] = isPrime(2 * i + 3)
auto flags = new bool[(max - 1) / 2];
flags[] = true;

foreach (i; 0..flags.length)
{
if (!flags[i])
continue;
auto prime = i + i + 3;
foreach (k; iota(i + prime, flags.length, prime))
flags[k] = false;

count++;
}
writefln("%d primes", count);
}

>Why would anyone correct a true statement?
Spoken like a true depraved sissy faggot
I bet if I shoved my hard cock in your face you'd slobber on it too you degenerate perv

>type a
that should've been a Z

>I bet if I shoved my hard cock in your face you'd slobber on it too you degenerate perv
Yes! Please do that right now!

Disgusting lewd LARPERS

Do you want to use a gun without a safety lock?
>This divides the community into anti/pro-rust

kute

>
{
}

I would love to shove my hard cock in your pretty gurl face and fine ass user

Wew lad is that a promise?

>gun without a safety lock
Sure. Just don't point it at anything you don't intend to shoot.

>inherently safe
Provably safe, where you cannot compile without it being proven. This is just programming with a very strong type system due to the Curry Howard isomorphism.

>An inherently safe chainsaw is entirely useless.
Shit analogy.

I wouldn't carry a gun without a safety lock in my pocket

You are stupid.

No promises but I might think of something for those luscious and hungry lips user

tell them shart in marter

Not a chainsaw but they have table saws now that stop when it contacts human skin. Look into SawStop.

Would be harder to implement in a chainsaw but could be possible. More important for table saws anyway, fucking things take so many fingers.

Safety locks can fail, better to just not leave guns to the professionals and keep the normie retards away.

...

Never thought a tripfag can be so annoying

>safety lock can fail
>so get rid of all safety locks
Flawless logic

*better to just leave guns to the professionals

I will pound that hot whore mouth like a pussy user~

how's your first week here going?

...

github.com/dlang/dmd/blob/master/samples/sieve.d

Lol

yes

>D
>plebbit
really makes you think

A large proportion of private gun owners are police, veterans and so on...

Probably a better programmer than you, gate keeper

>Probably

Why would one do that? Just go on the internet and tell lies?

How can you compete?

3e.org/dmd/cv.pdf

>gate keeper
is this supposed to be some sort of insult? i really don't get your kind.
oh, by the way, you're not welcome here.

...

really wanting to learn python but all the stuff I've found is for people who have at least a basic understanding of general code which I don't, do you guys have any website or software I can use to learn the basics and progress? thanks

Well, you are not good at keeping reddit away. Have you been able to do one thing right in your life?

>code
>python
>do you guys have any website or software I can use to learn the basics and progress?
Yes, I recommend your home website. Also know as reddit

Python is just as unsafe as c++ if you use the C FFI

You are too late, gatekeeper

>*screenshots this and posts it in reddit*
:D

optimized

stupid shit poster

Seriously: piss off. Your kind is not welcome here.

...

No.
t. reddit :DD