/dpt/ - Daily Programming Language

Did I fuck up Sup Forums?

Old thread:

Other urls found in this thread:

en.wikipedia.org/wiki/Telephone_keypad#Key_tones
github.com/ksimka/go-is-not-good
twitter.com/SFWRedditGifs

First for Idris

dpt_without_anime_op("60268718").

fucked_up_thread(X) :- dpt_without_anime_op(X).

?- fucked_up_thread("60268718").
true.

how do i get an input in a phone call?, for example if i ask the user to enter a 1 in the phone how i obtain that input.
i am obtaining the inputs through a modem and i am developing a windows program

DTMF?

This image is fun. The longer you stare, the more you find.

en.wikipedia.org/wiki/Telephone_keypad#Key_tones

Phones usually dial with a sound using these frequencies.

this

>le phd in cs face

Sounds. How telephony systems work is fascinating.

bellcore fsk, but how do obtain an input from usb port?

C
+
+
1
7 7
1 1 1
+ + +
+ + +
C C C
+ + +
+ + +
1 1 1
7 7
1
+
+
C

C++ 17 isn't very good

Here's a challenge: Find a reasonable project requirement or other reasoning for each silly part of that block, without contradicting any other reason.

What are you using to plug it in your computer as USB?

>scala-lang.org, Aug 2013
>Construct elegant class hierarchies for maximum code reuse and extensibility

>Silicon Valley S01E01, Apr 2014, speech from a startup CEO
>We're making the world a better place through constructing elegant hierarchies for maximum code reuse and extensibility

JavaScript is the English of programming languages.

Web frameworks are the ebonics of programming languages.

a modem with caller id support, but doesn't have voice support

Fuck anime

> The crew went to TechCrunch Disrupt, a startup competition also featured in the show, to film footage of the crowd, Berg explained.
>During the review process once the footage was woven in, another editor criticized the crowd shots for not featuring any women and blamed Berg for the oversight.
>"She said those crowd shots were absurd," Berg told the crowd at SXSW. "Those were real shots of the real place, and we didn't frame women out. The world we're depicting is f---ed up."

That would be C nigger

Checked and congrats on becoming a glorified codemonkey.

Do you need to learn Java before learning Scala?

From that family, C++ is a far better match with all the inconsistent, poorly thought out crap it has bolted onto it.

Java langs are a complex hierarchy.

You need to start Javascript so you can understand the foundations of Java. Then Java. From there you need to learn Clojure so that when you dive in to Scala you understand its scopes and methods.

It would be a good idea, in case you want to interact with or utilize java components in your application.

There's a lot of well tested solutions and java libraries out there, so it's worth reducing any language friction up front.

I feel like there's some way to optimize that snippet on OP's pic.

>You need to start Javascript so you can understand the foundations of Java

Oh you silly Billy.

They said English, not American.

JavaScript is actually the best dialect of Java because it eliminates most of the boilerplate and has the strengths of both C and Haskal.

C is an objectively decent languages for its domain.

>tfw C program with >1.5K loc has weird as fuck string problem
>in a very special case it returns a cryptic string
>can't fucking figure it out why
>in small inputs it wroks perfectly
>in big ass inputs it just throws this magic string garbage
>i just do
if (!strcmp(rb->pos,))
return NULL;


oh well

I'm looking log .mp3 files that are played on my computer, basically like the last.fm scrobbler for anyone that's familiar. Eventually I want to set up a SQL database so I can monitor my listening habits and have quick queries about it.

I have no idea how I'd approach it, though. How would I even log audio files that I play in foobar?

...

What the hell am I reading?

nvm solve it.

forgot do do memset

i'll pm you guys the solution

>foobar
Write a plugin?

Or write a program that monitors all HDD access and logs all .mp3 access.

Scrape whatever file access event system the os has.

This symbol is very triggering.

letters?

Javascript is a foundational language, which is why silicon valley uses it instead of newer, web oriented languages such as Rust and SNOBOL.

Rust is more influenced by Haksal than by Java.

Rust is more influenced by C++ than Haskell

>no HKTs
>strict evaluation
>no way to guarantee TCO
Yeah, I can really feel that Haskell influence.

Nobody asked about C++.

View > Console > Write Log

It contains many other things, but if you're good enough to clean it, it could be your solution.

Yeah well I don't see any AbstractOutOfMemoryExceptionFactories in Rust either.

>>no way to guarantee TCO
That's being worked on. And besides, that's more of a C thing anyway. TCO isn't needed when you have first class functions.

where can i talk about data analysis programming in R and Python?

I work in the financial services industry

>That's being worked on.
Just like entirely removing the GC in D. I'm not interested in vague promises of necessary features.

where do i get started with embedded shit

>where can i talk about data analysis programming in R and Python?
anywhere you want?

just don't expect everyone to listen to you.

>Python

ill listen to you user

D version:

bool getConfirmed() {
scope(exit) confirmed = confirmed ? false : confirmed;
return confirmed;
}

>sqt
Oh hey, I'd forgotten about the Stats and Quant Thread.

is sgt a general here?

sQt, not sGt. It's fairly regular.

C version

int getConfirmed() {
return confirmed;
}

>changing state in a getter
holy shit op just call your function confirm or do_confirm or something

well there isnt a "data analysis general" or similar as far as I am aware

thanks

I like R because I can quickly analyze massive data sets I work with, but it takes me like fucking 10 minutes to upload like 3.5gb of data, so I think I am going to start full time using python....but ggplot2 is amazing for presenting data and at the office im "that guy who makes amazing pitchbooks/graphs" so idk, fuck


Also when I run monte carlo sims I have to leave programs running overnight just to get enough data to be able to meaningfully analyze a hypothesis

I KNOW it can be done faster in "lower level" languages, but I never learned comp sci (math major) so I cant just pick up C and write what I am doing in it

If confirmed is true, its value is inverted.

Tell me about Go, why does it suck other than it was designed to stop pajeets from fucking everything up?

Seems good tbqh

github.com/ksimka/go-is-not-good

This

> error type is simply an interface to a function returning a string.
> lacks pattern matching & abstract data types.
> lacks immutable variables.
> lacks generics.
> lacks exceptions, and instead uses error codes everywhere,

Error codes are great. If your language has features to make it easy to handle them, like Rust's try! or Haskell's Either (or MonadError, or whatever).

what's the matter, pajeet? can't handle c++17?

Excuse me, Sir?

How much code does Reddit keep private from the public Github repo?

I've been looking through the code to see if there are any methods for checking one user using multiple accounts to vote on posts and don't see any methods for accomplishing that info directly.

There's some stuff for checking what IPs are accessing accounts with a comment about "send this info so we can investigate". They can't be doing vote manipulation checking by hand? Or do they keep their vote manipulation checks private

I wanna learn python. What do I start with?

bool getConfirmed() {
bool ret = confirmed;
confirmed = false;
return ret;

Python.

You can learn Python and then use C and C++ binding for the parts where you require speed.

Wanting to learn python is like wanting to learn how to read. There are resources everywhere. Because of how easy the language is, every resource is technically good enough.

90%

Threadly reminder that dlang-chan is not dead; she's going to have her GC tumor removed (eventually); and she's super duper cute and easy to prototype in! Say something nice about her, /dpt/!

Of course Reddit is going to hide stuff like that. You think Reddit will be happy if people discovered it is a shilling zone via their own code?

should i ask about help with a programming project here or /wsr/

>finally made it to computer programming classes in college
>tomorrow is my first day
>mfw btfoing everyone tomorrow with my extensive linguistical programming knowledge from years of daily programming threads

b-but you're doing an assignment each time user

dumb frogposter

NO FUCKING WAYY

HOW LONG AS THIS BEEN A THING?

bool getConfirmed() {
return confirmed && !(confirmed = false);
}

An assignment that changes nothing is faster than a branch

Yeah. That is called Autism

She severely needs to get a rich daddy.

I'm sure the first question the teacher is going to ask is "who here knows how to fizzbuzz" and you'll answer correctly and instantly be awarded your diploma.

forever

bool getConfirmed(void) {
return (!(confirmed = !confirmed));
}

This is wrong. confirmed should not be set to true if confirmed was false.

thanks user

confirmed = \empty

I've seen code like this

pls help I'm going insane

using angular I want to iterate through a json array containing arrays.


{{key}}
{{val}}


gives pic related

and when I try to



{{key}}
{{value}}

nothing shows up in the table

what the fuck am I doing wrong?
>blah you need to know the json identifiers in the arrays
I don't know them because I python "jsonify"s the results I get from GETs

It sure will help though if he's lurking, I had a lot of problems when they introduced us with javascript last year, the syntax is absolutely haram.

No user!

I've been going to Uni for a couple months now, hide all prior knowledge!

It's taken me a while to grasp but 99% off the people in CompSci come in with no prior knowledge, they just expect to learn all this stuff when they get there.
I've finally managed to make some good mates but they get quite and defensive whenever I whip out previous projects. They will be thankful when they realise they can come to you for help with their work though.

Also the professors there are pretty thick, most of them are working with severely outdated limited knowledge, they do not care about their fields 90% of the time, I know it's a """place of learning""" so you'd expect them to care but they don't.

Don't make the same mistakes I did, these people are massive casuals in disguise!

>Angular

Pffthahahaha

no bully, how fix?

This. The worst meme you can fall for is the pretty girl that needs your help. Don't do it. I have seen too many retards fall for it and end up doing 80% of some CS girl project.

This, just shut up and keep your head low.