/dpt/ - Daily Programming Thread

What are you working on, Sup Forums?


Previous thread: Next thread:

Other urls found in this thread:

github.com/enfiskutensykkel
blog.xinhong.me/post/sublime-text-vs-vscode-vs-atom-performance-dec-2016/
github.com/andlabs
twitter.com/NSFWRedditVideo

Kill yourself, trapfag.

Post githubs

Might as well use a tripcode

does Python have a future?

im trying to print an output of a program using sed


name: JohnDoe
address: mulholland drive
account: 0000-0000-0000
balance: $100.00
name: JaneDoe
address: mulholland drive
account: 0000-0000-0001
balance: $120.00

i need to get the last to lines

account: 0000-0000-0000
balance: $100.00
account: 0000-0000-0001
balance: $120.00

but it returns as
account: 0000-0000-0000balance: $100.00account: 0000-0000-0001balance: $120.00

So add a newline

To add to this, \0\n

Not sure what language you're using, but languages like c# and java also have writeline- functions which automatically add the \n

>not casting malloc
>enjoy your stream of warnings and not being able to compile c++

How do I find a business that I can write software for? How do you people find clients in need of automation or sell them on software solutions?

I've been doing software development for a few years at several companies and I'm honestly tired of getting a pittance of the money for a comparatively huge amount of actually producing.

i'm trying to do it on a command prompt, I have a text file that will create a new one listing the the trimmed text

sed '2,4 !d' >> accounts.txt

>warnings
Void pointer conversions are well-defined in C.
A compiler would not emit a warning for that.
>not being able to compile c++
What a pointless thing to do. Most non-trivial C code cannot be compiled as C++, especially past C99, and even then, there are semantic differences between the languages that makes the whole thing a fucking minefield.

Kill yourself, normal human being.

Why don't you use grep?

When you say command print, do you mean a bash shell or a windows command prompt?

command prompt

i don't know how

accounting.exe | sed '2,4 !d' >> accounts.txt

>not being able to compile c++
Use extern 'C'
You wouldn't use malloc in a C++ file, would you ?

i meant function, not file*

grep checks each line against a regex. If it doesn't match, the line is skipped, otherwise it's output verbatim. So you want something like:
accounting.exe | grep "account|balance" >> accounts.txt

braces

it didn't work user, thanks btw

You are given some code from a benevolent entity. The entity requests that you demonstrably prove that you know exactly how the inner workings of the code work. You aren't allowed to execute or tamper with the code at all. How would you prove yourself?

>stackoverflow said so

IMPULSE RESPONSE

what do i get in return?

grep doesn't use regular expressions by default you need to pass -P

You tell the being that you gleaned all of your insight from stack overflow. The entity quickly shifts from benevolent to malevolent and banishes you to the realm of new stack overflow questions for eternity.

Big data. :^)

Why is the Sup Forums image server such a slow piece of shit?
It wasn't always that bad.

package main

import "fmt"

func main() {
fmt.Println("Hello world, you fat piece of shit")
}

babby's first hello_world.go

The Global Regular Expressions Print utility doesn't use regular expressions by default?

You mean it doesn't use perl's extended regexp without -P

Why is sublime so expensive, I want to support the dude but seriously $70? It makes sense I guess if programming was my full-time but it's not really. Just seems like a waste

e : \x.e
e e
x

package main

import "fmt"

func main() {
done := make(chan struct{})
go func() {
fmt.Println("Hello world, you fat piece of shit")
done

Looks worse than sepples.

Last bug fixes on a Xamarin app for Android and iOS for a product we're releasing next week.

vs code is better anyway

just pirate it then and buy the license later if you ever get to make money off programming

>Proprietary text editors
What the fuck?

package main

import (
"fmt"
"sync"
)

type Broadcaster struct {
m sync.Mutex
listeners map[int]chan

Stop it. ;_;

like such?

william@DESKTOP-PC:~$ cat ass.txt
name: JohnDoe
address: mulholland drive
account: 0000-0000-0000
balance: $100.00
name: JaneDoe
address: mulholland drive
account: 0000-0000-0001
balance: $120.00
william@DESKTOP-PC:~$ cat ass.txt | sed -E '/^ac|b/!d'
account: 0000-0000-0000
balance: $100.00
account: 0000-0000-0001
balance: $120.00

I use Emacs, but I can understand if some don't want to learn a shitload of shortcuts and just want to care about their code.
The learning curve for Vim and Emacs is steep (I haven't programmed anything in Emacs Lisp yet), VS Code and Atom rely on relatively inefficient Javascript VMs, and things like gedit are a bit too basic for their own good.

github.com/enfiskutensykkel

>VS Code and Atom rely on relatively inefficient Javascript VMs,
This is only a problem with Atom. VS code is actually optimized.

it's time to lose weight, friend

är det du som hela tiden brevar på norska?

notelemetry.obj

They made several changes. It blocks hotlinking too. Seems to be on a new CDN.

blog.xinhong.me/post/sublime-text-vs-vscode-vs-atom-performance-dec-2016/

hmm yes """optimized"""

Meh

Nei

> Using a website to edit your code

lel

t. fag

...

I don't give a fuck, and also /fit/ is filled with angsty teens that are insecure over their bodies.

Does my body trigger you somehow?

nice argument

No, it just could look better.

kind of unrelated to thread but can anybody give me the link to a good online command line guide (beginner). Everything I find is either too complicated to unrelated.

you're all nerds hahahhahahahahhahahahahhahahahah

Well, thanks for the though. I may consider it at a later point, but I honestly just don't really care enough bother at this point in my life.

man command
command --help

cd
ls

You can't go wrong with those.

ok thanks, im completely new to this but I really enjoy it

back in class

But write-line is a common lisp function

>But write-line is a common lisp function
java:
System.out.println("foo")

c#:
something similar

user you should really consider changing your body.
your eye rings make it look like even your eyes want to leave your disgusting, fat body.
not to mention if i lighted up your hair you'd look like hades for an entire fucking year.
you're looking into the camera from below and you STILL look fat as fuck, not even fat landwhale tinder bitches look that fat.
all apply to you.

I still want her number

user, I don't fucking care. I'm sorry you get triggered by seeing fat people, but that's not my problem. In fact, I'm tempted to put on even more weight just to make you more upset.

maybe I could be your girlfriend?

sure

Please don't eat me.

This wasn't og number asker, but sure if you're a cute girl

i'm a qt3.14 girl with a feminine penis, if that's okay? we can hack c together

I would if I were gay but I'm not, sorry buddy but thanks for the offer

this isn't me but it's pretty much spot on

HOW DO I LEARN C

like anything else

looks like someone got jealous over that guy's github, fucking kek

that's a weak way to compensate for your weight OP

Google a tutorial, read a few books, wear striped thigh high socks.
c is the most ladylike language, so try learning it alongside embroidery and etiquette training for optimal results

>The logo of Mono is a stylized monkey's face, mono being Spanish for monkey.
what did they mean by this?

we can't have nice things

do they know you're posting this on Sup Forums?

I, for one, am jealous of the skill of a person that deems an A* implementation worthy of his (xis?) github.

explain

>Google a tutorial
I can't know which ones are memes and which aren't
>read a few books
I ordered a Modern Approach 2nd edition and K&R2. Am I good?
>wear striped thigh high socks.
lmao

is there a test you can take which proves you're a master of that language?

yeah, it's called work experience

>master of the language

I'm (not ) but I use my github for all sorts of crap. It's handy to have some common algorithms easily available, which is in my opinion what github is for.

Anyway, I knew what I was getting into by posting my github on /dpt/, people here are too busy shitposting than actually discussing progamming.

how does that prove anything? what if you just programmed specifically gui for 10 years? definitely not a master

>>wear striped thigh high socks.
>lmao
I don't know what to tell you if you're this clueless. maybe programming isn't for you

This is a prime example of why no one will ever post his github on here.
SUPER bully EXTREME ~~!

I've posted a link to my github account on here before.

i dont find it autistic.
I just want to know where my knowledge stands with said language, so I can say without a doubt, "I'm a master at using Rust" or whatever.

then you should reconsider your life choices

depends on the language and what you're working with, and you're probably going to specialize in one or a few areas so maybe you're good with physics/math stuff but not networking for example

you could be a master of GUI dev

Do you already know another programming language ? If you don't, learn the basic constructs of imperative programming (maybe pick Python instead for that)
Once you know that, then learn how pointers work, the difference between memory allocation on the stack and the heap, how to structure your code in modules with header files, how to compile and link them together, macros, what can or can't produce undefined behavior and how to write efficient code with the language.

heres mine
github.com/andlabs

and i think he's a fat fuck