Previous thread: What are you working on, Sup Forums?
/dpt/ - Daily Programming Thread
>Posting before the bump limit
>Frogposting
Report this thread.
Do not post in this thread.
>butthurt trap poster
what a surprise
Don't you ever tell me what to do faggot
o shit waddup!
OH SHIT HERE COME DAT BOI
how do i make a program with lisp? racket particularly. as in, a file that you can run. right now i'm still just doing the line by line thing
you don't
You have been visited by the crossdressing C programmer of Shimoshina Academy!
Good performance, triple indirection, and tail call optimization will come to you, but only if you post "Keep overflowing the stack, Hime!" in this thread.
DELETE THIS
this cancer is not acceptable just because it has some programming lingo in it! this has gotten deletion + ban before and it should again!
Why is cout so fucking gay? printf is much easier to use
>crossdressing
Keep overflowing the stack, Hime
c++ is a meme
snopes.com
really?
I need a full text adventure game, but there is a caveat. It has to be written in a language where it can be edited and compiled from. Practically every one I can find that prints in console is pre-compiled or has some library that isn't compatible with my system. Or it runs in dosbox which I can't seem to access the memory in.
The idea is for it to accept an input and me modify the program so it dumps the response to file
I like C++ otherwise but cout is just fucking stupid
Trying to come up with some code that'll let me play music from another laptop on the same wireless network as mine. I'm a noob so I have no idea where to start. I want to integrate this into another project of mine, any suggestions?
>any suggestions?
start by posting in the right thread and describing your problem properly
Keep overflowing the stack, Hime!
nice samefag retard
Dumbass frogposter
this is a frog thread deal with it fag
You don't like using meme arrows when coding?
You compile a file.
I don't know how to compile files with racket but it's pretty simple with chicken scheme
csc -o foo foo.scm
write your own
considering that but it would take forever to write a proper one compared to adding a few lines to an already finished program
I didn't understand what you were trying to do from your original post, mind explaining more?
Does anyone know a good algorithm for scaling down images? Images I print in my console have to be pretty damn small.
Average color in successive rectangles
Wow it's really that easy?
I thought it had to do with maths n stuff
well this is a project for /qst/
I wrote a scraper a week or two for a thread which takes each line as a command
ultimately I'd like to write a bot so that people can just respond to the thread and create their own text games, and the bot would act as a console.
So to do that you need a scraper to get the inputs and feed them to a program (which I have), you need a way of processing your inputs (a game which dumps to file, since merely printing it is useless), and a way of returning to the people that post. Two ways to do this, the first I'll try is a pastebin which edits itself and creates sessions. The second would be to buy a pass and create a bot that way. Unfortunately I could get banned for that so I'll go with the pastebin idea first.
See most text games run on dosbox or are in archaic languages that can't be run any more. So I've been looking for a good one for a while
Have found a promising library in python though, just looking for other options.
This is one of the worst /dpt/s we have had for quite awhile.
This is what happens when you allow pre-bump limit threads and frogposting.
bait
i want to learn c# but i can't find a begginer (to c# and programming in general) book/site that looks good.
got any suggestions?
tell me why JavaFX is bad
you can't, right?
Can't you redirect output of [text adventure engine] to a file?
>pre-bump limit threads
this includes the trap threads, fag.
because it's outclassed really hard by swing
isn't JavaFX supposed to be easier and better? ie: supporting css styling
no, because none of them technically run from the command line. They run within their own environment
like once you've written a command starting their process and beginning the game you can't access those outputs by piping to file or anything, because it just doesn't accept console commands anymore.
Like it would be nice if, for example you could write
>emacs dunnet -nogui > out.txt
and have every command written there but you just can't
>Java
took like 3 seconds to find this
libgen.io
you should learn programming first then pick up a book on any language you want. learning a new language isn't that difficult
can /dpt/ recommend a book for GUI design?
i've finally learned layouts and writing GUIs without a form designer but i don't know how to make a GUI look good.
what's bad about it?
It's a gift, you either have it or you don't. You can't learn.
what's good about it?
he's memeing
No, I honestly think Java is awful.
c-can I get that script?
because you fell for the meme
especially if you think C# is good but java is bad you're just stupid or misinformed
No, C# is shit as well.
Any object oriented language is shit, especially languages that force it.
>what are static methods and fields
aaaaaaaaaiiiiiiiiiiiii itttssss da boooyyyyy
>static methods
Pointless. Why do I have to create/define a class just to use a function?
>static fields
A global variable.
Anyone here has before writed her own customized controls for XAML? There's a good book for that?, so long I've only learned about built-in controls.
C# is pretty good desu, I mean, i can pinpoint like 10 things I don't like about it, but I can do the same for every language I know, even C (my favorite).
class ProgramName {
// ...
}
so this is all you've got, the "forced OOP" just because you have to write this "boilerplate"
idiot
Who the hell writes their programs this way? That's just fucking stupid. I would just use a language that I don't have to fight to do even the simplest of shit.
Even with that shit, I would have to define ALL of my functions in a single file.
I went through the codecademy course for python but c# is recommended by a bunch of people I know so I figured I'd give it a shot.
What's wrong with my function?
Its telling me it can't convert explicitly from the linq type to the generic type or something
IList scores = new List();
public void Pull()
{
//get message
string response = netInterface.Get();
//parse location field and add scores
string[] responseCSV = response.Split(',');
foreach (string item in responseCSV)
{
List score = new List();
scores.Add(item.Split(':'));
}
scores = scores.OrderByDescending(x => int.Parse(x[1]));
}
kill yourself IDIOT, you're stupid and wrong, i'm not gonna waste more time on you, enjoy your shitty C
Actually I've done this before- there's a Z machine out there that takes a commandline option to output text to the terminal and no fancy GUIs.
Enjoy your OOP and hidden mutable state, you shitty cargo cultist.
fuck off and die, retard
Pssssh I wish I was dedicated to that
Why do Indians get so defensive?
Can't you find the nearest designated street, Pajeet?
more than an hour later you come up with this edited screenshot lmfao you're pathetic dude get a life
stay delusional, nathaniel
Which programming languages have the most jobs? I'm going to try to learn two or three this summer.
java
C++
Alright you wet socks, answer me this:
I am cucked into working with java. Is Scala worth learning, or is it just another epin maymay?
Okay mom, which should i learn first? Any books I should buy to help me on my journey?
Dude I was sleeping. Can I not praise Hime and take a quick nap?
only 1 or maybe 2-3 fags in total unironically praise hime, the hime poster was revealed to be samefagging
Are there any good resources that show the underlying logic behind C++ abstractions? I'd like to be able to compare what I write to equivalent C and assembly code to see if stuffing my programs with a bunch of convoluted garbage is actually beneficial.
Guess im one of those "fags" but I wouldnt doubt that Hime poster would samefag
which abstraction in specific would you like to know about? I can take a stab at explaining it if you've got a specific one or couple in mind.
>Keep overflowing the stack Hime!
>unironically praise hime
You're an idiot.
Compile your code with -S and be disgusted.
Don't worry about it, they're all worse than a pure C implementation.
Look at the assembly of your compiled c++ program. There is an option in gcc.
Not any one in specific, I was looking more for something like a reference.
>-S
Fuck, using it didn't even cross my mind, thanks.
>don't want to write function to do thing
>have to get around to it sometime
>just start writing up everything else that can be done without writing said function
>now can't really progress without writing function
In other news, I have written over 350 lines of C in the past 4 hours!
I made a small SDL2 + GLEW / OpenGL program in linux (compiled with clang 3.8) and I'm trying to port it to windows, fucking visual studio is shitting itself.
Is mingw a better option? I just want this shit to work.
It's too damn messy
What OS do you use /dpt/?
yes mingw should be much less painful.
What are you working on? I'm working on SDL + OpenGL program too. Mine is a minecraft clone.
Arch GNU/Linux
Debian GNU + Linux
just a small 2D framework, I want to make a geometry wars clone
the fucking compiler is throwing so many errors, might as well try something else before I even start debugging that shit
Lubuntu
Gentoo
Windows 10 right now. Will be switching back to Linux at the end of Spring quarter.
xubuntu and windows 10
Does anyone here know what the inner `static` in the following C code means:
void f(int x[static 2]);
I'm not asking because I want to know what it means. I'm asking because I'm wondering if anyone here knows about this obscure feature that I've never seen in real C code. So please only reply with "yes" if you don't have to look it up.
MacOS
Without googling: If I recall correctly you're saying that the array is of a minimum of two items?
I know what it means. It means that x must point to an int array that has at least 2 elements.
Yes, it's a very obscure feature. I only know that because sometimes when I'm bored, I skim through the C standard.
OSX