Share Programming Exe thread?

mediafire.com/file/18ffycra1lclsos/Greentext_Mad_Lib.exe

Can I post short programs here in technology?

Share short programs thread?

Preferably if C++, i'm learning that.

The program i'm posting is based on that trendy Mad Libs type of story that sells hot-fire to kids and adults. (Yes, they had 50 shades of grey for fucking adults)

Other urls found in this thread:

mediafire.com/file/xsemk44fe5catdx/GreenTextSilliness.cpp
hastebin.com/wanopagoho.cpp
my.mixtape.moe/jppvaj.bat
stackoverflow.com/questions/13436408/what-is-00-and-how-does-it-work.
twitter.com/SFWRedditGifs

Post source or gtfo. I ain't clickin' dat shit.

Here's some code, to tell you it's legit. You gonna post any C++ or just be a cry-baby who can't use an anti-virus to scan exe?

> posts screenshot to prove legitness

Sounds legit thanks for the .exe ;)

mediafire.com/file/xsemk44fe5catdx/GreenTextSilliness.cpp

Here ya go pussy cats.

To be fair, you should be sharing source only, rather than distributing binaries. No one has any reason to trust a random .exe.

Use something like hastebin.com or gist.github.com lad

>uses c++
>uses c style strings

Mirrored: hastebin.com/wanopagoho.cpp

>Overlooks the fact i'm learning C++, not
yet have developed all the functionalities, i' m still learning.

I know that's used to simulate string with arrays in C, but i'm still learning.

Why did I create this goddamn thread? I know it would end up derailling.

This serves me as experience.

desu you repeat yourself a lot in the code. many of the phrases are repeated. you could try using something like a text string with the contents and replacing the values on the string with the input, also try loading the story from a txt file.

your indentation is kinda messy too.

You should be grateful for criticism. If you can't stand being told that your work is shit, you shouldn't be programming, and you shouldn't be posting on Sup Forums for that matter. Eventually you will reach the zen moment where you realize that everything is shit, and you will not be so bothered by these sorts of comments.

I appreciate critcism, but no one posted any programs, and that was the point of creating this thread.

Er, mind posting source file or screenshot to enlighten me?

You mean putting the string files in a structure?

>Share short programs thread?
Here is a very short program: my.mixtape.moe/jppvaj.bat

do you really need to use cout for every single sentence? java does not have this problem.

You don't, but otherwise it will end up being messy.

You can add a "\" at the end instead of the "
to extend towards the next line, I only used it in this case so the story can be read neatly in the command window.

What's your problem? I downloaded the batch file, but it did nothing visibly helpful, infact when I tried to close it, it would freeze. Not to mention windows entered some sort of compatability black version on the desktop.

Maybe it did have other function, but the batch ran horribly on my PC for unknown reasons but I doubt it.

all the code inside your if blocks should be a level of indentation higher. select it and press tab

eg.
if (cond) {
code;
}


about the strings, i mean like, write a few text files like this

"Hi, I'm |NAME| and I'm |AGE| years old"

load its contents with c++ (IIRC it's on std::iostream) and replace |NAME| with the name, |AGE| with the age, etc

i wouldn't be surprised if c++ doesn't have a string replacement function though. if it doesn't, disregard this.

also, . you don't need to cout everywhere. you know, if you do it like this:
cout

cout

>I downloaded the batch file, but it did nothing visibly helpful, infact when I tried to close it, it would freeze.
Wow. You are either very young or RPing pretty convincingly. I'll explain.

FYI, what I posted was a famous fork bomb for Windows. stackoverflow.com/questions/13436408/what-is-00-and-how-does-it-work. I never thought you'd run it. I still doubt you have, but just in case, take it as a very low-cost lesson in how you should not run code from Sup Forums unless you fully understand it. It could have been ransomware.

I can see now that the indent is used to make the blocks of code look cleaner, and how you taught cout doesn't have to be used multiple times, thanks Mr.Animu user!

However, you lost me at strings, don't you have to declare the char with the char arrays first? Don't I need to put header too?

dude just read a programming book. c++ is for cucks use java instead unless ur making gaymes

I heard about term double attack, and buffer-overflows, but I never thought it could be used in an .exe.

I thought it would usually be done against servers through hacking or insecure programming.

>I never thought it could be used in an .exe.
You should seriously read some sysadmin-type book about how Windows works.

>Gaymes

I'm only learning it to use Unreal Engine later on, you caught me.

Do I really?

If anything I learned today in Sup Forums, it is to never post .exe files and only post sources, vice-versa.

I'm not gonna dedicate to learn all that jargon.

>Before I leave this thread to learn some C++
Yes.

first, stop using char arrays. read up on std::string.

the idea is, have a few text files in the same folder as the program/code, name them something meaningful. as this program seems to differ its output based solely on the gender variable, it would be wise to name the files the possible values for gender.

some pseudocode for what i mean is:
string fileContents = read(gender + ".txt");
fileContents.replaceAll("|IDOL|", idol); // here idol is the variable the user inputted, and |IDOL| is what will be replaced
// repeat this for all user input variables
cout

It doesn't have have the "replaceAll" method.
Writing up every variable with [ ] if it did work sounds much more complicated.

Thanks for the previous help, but this seems too convoluted for what's needed to finish the job.