Time to find out how autistic you really are...
cout or printf?
Time to find out how autistic you really are...
cout or printf?
Other urls found in this thread:
youtu.be
youtube.com
twitter.com
Can't you find something more interesting to bikeshed about?
>bracket placement
>cout or printf
>return 0 or return EXIT_SUCCESS
FUCK OFF YOU NEET
I bet you're the retard who posts "wasted another day not learning how to program" threads.
writeln
cout
So your answer is "really autistic"?
"".format()
Niggerlicious
We wuz kangs
What's the difference between iostream and stdio?
cout like a normal person
>he doesn't drop down to inline assembly and manually drop characters into the stdout file buffer
Fucking faggot.
puts
top kek
...
Go back to Python and Reddit while you're at it
You retarded?
System.out.println
char **argv or char* argv[]?
cout unless I'm printing thousands of things at once
outfile
(...) show
Based
echo "go fuck yourself OP"
just compose it into a single string and push it into the out stream
...
I'm more of a System.out.println(); guy myself.
fprintf(stdout, ...)
System.out.println("my dick is small");
vs
std::cout
__asm__("syscall"::
"a"(__NR_write),
"D"(1),
"S"(str),
"d"(strlen(str)));
...
read amount;
echo "I am OP and I sucked $amount cocks today.";
sudo rm -r /
console.log();
;)
you forgot the newline for cout
echo
printf
Don't have to #include
=)
cout
printf
std::cout can go suck a dick.
println! is superior to everything in this thread.
For output - printf, because you can change the format string in runtime. For input though, both cin and scan-functions have their uses, sscanf in particular.
>deliberately making your program less portable
Stallman would be disappointed
I don't care
if I already included some shit I might aswell use cout
otherwise printf
you're all fat ugly neckbeards
You are autistic if you start arguing about which one is better
cout cause i like to autistically shift shit
>cout cause i like to autistically shift shit
what am I reading
cout in c++, printf in c
cout
that's not a shift in that case
why do you want to trigger Sup Forums
don't you have something better to do
no i actually don't have anything better to do right now
ok then I guess keep going
If in cpp, cout, if in C, printf. That fucking simple
Console.log('fizzbuzz"):
printf("Some ints I want to check: %d %d %d\n", int0, int1, int2);
vs
std::cout
>i'll construct a highly improbably, poor form test case where my particular archaic format is slightly less verbose and then pretend this means it's obvious that said archaic format is better
printf
lmaoing at languages without string interpolation. But format strings(not C ones but rather C# ones, where you can change the order of variables) are useful for multilang software.
fpbp
std::endl also flushes the stream, causing slowdowns in large printing (Replace with \n and flushing the stream at the end).
It's also not really contrived, I find myself printing multiple values at once a lot.
>bracket placement
The best is keeping it all consistent but the best is also newline braces:
void Blarg(Honk thing)
{
}
>cout or printf
cout forever
>return 0 or return EXIT_SUCCESS
return 0
Nobody is forcing you to use endl instead of \n.
what the fuck are you talking about.
Real autists actually use putchar
do{
putc(*string,stdout);
}while(*(string++) != '\0');
;^)
static void Main()
=> WriteLine( "Hello, World!");
(format t "format is so much better than both, ~a~%" 'faggot)
my nigga
???
neither?
mov edx,len
mov ecx,hello_world
mov ebx,1
mov eax,4
int 0x80
Console.WriteLine
Fuck off pajeet
COUT IS FAR MORE POWERFUL! OUTPUT STREAMS ONLY!!!
ding ding ding this is the correct answer anything else means youre a fag
I really hate the syntax of streams.
what do you hate about it?
I don't like using
I kinda agree actually, but i still much prefer streams to printf. the syntax of printf is far more ridiculous IMO
cout is trash. cin is alright though.
What's ridiculous about it? You give it a format string, and then follow up with the appropriate number of arguments of the appropriate types and that's it, it's basically no different from any other function call.
dry
I should just be able to give it an int without needing to tell it it's an int
[>.]
Like in C# then.
like c#, python, c++, haskell ... every modern-ish language has this
std::string s = fmt::format("{0}{1}{0}", "abra", "cad");
x86 assembly does not have this and it's used everywhere
x86 assembly is not made for human beings to write
this. writing in assembly is a sign of delusion - thinking you can optimize code better than a compiler. in almost all cases it's a huge waste of time
this question is dildos. cout is just niggerlicious
Yeah I did
printk
puts
ofstream
if you're using C++, use C++ only.
So cout.
>not holyC
"Hello World\n"
>i never want to output a number of values in a convenient and readable fashion
std::cout with a custom std::streambuf to write directly to video memory.
operator