[Boards: 3 / a / aco / adv / an / asp / b / bant / biz / c / can / cgl / ck / cm / co / cock / d / diy / e / fa / fap / fit / fitlit / g / gd / gif / h / hc / his / hm / hr / i / ic / int / jp / k / lgbt / lit / m / mlp / mlpol / mo / mtv / mu / n / news / o / out / outsoc / p / po / pol / qa / qst / r / r9k / s / s4s / sci / soc / sp / spa / t / tg / toy / trash / trv / tv / u / v / vg / vint / vip / vp / vr / w / wg / wsg / wsr / x / y ] [Search | Free Show | Home]

/dpt/ - Daily Programming Thread

This is a blue board which means that it's for everybody (Safe For Work content only). If you see any adult content, please report it.

Thread replies: 332
Thread images: 34

File: 1484943715765.gif (1MB, 1280x1024px) Image search: [Google]
1484943715765.gif
1MB, 1280x1024px
What are you working on, /g/?

Old thread: >>58656123
>>
.device ATmega128
.nolist
.include "../m128def.inc"
.list

.def temp=r16
.equ LEDPort=PortE
.equ KeyPort=PortB
.equ KeyPin=PinB

rjmp Init

Init:
ldi temp,0b00000000
out DDRB,temp
ldi temp,0b00001110
out DDRE,temp

ldi temp,0b00000000
out KeyPort,temp
ldi temp,0b00000000
out LEDPort,temp

ldi temp,0b00000111
Start:
sbis KeyPin,5
rjmp SET_Press
sbis KeyPin,6
rjmp TST_press
clt

rol temp
out LEDPort,temp
ror temp

rjmp Start

SET_Press:
brts Start_1
set
inc temp
Start_1:
rjmp Start

TST_Press:
brts Start_2
set
dec temp
Start_2:
rjmp Start

How is my assembler, /dpt/?
>>
>>58661514
nobody competent would be uses windows , "command.com" .. which is the garbage they started with, remained with
>>
>>58661657
I see only C code there.
>>
fuck you for posting an anime image
>>
>>58661785
Ignore this thread, it is duplicated. Real thread here: >>58661502
>>
>>58661785
>>58661791
proxy samefag
>>
>>58661657
I'm not entirely sure what you're saying here.
>>
File: 1479804559600.jpg (166KB, 800x1071px) Image search: [Google]
1479804559600.jpg
166KB, 800x1071px
Is this not the real thread
>>
What makes people say Python is a bad language?
>>
>>58661861
>using a babby language instead of C

Is what your average fizzbuzz developer would say.
>>
File: 1474456344652.png (244KB, 986x810px) Image search: [Google]
1474456344652.png
244KB, 986x810px
>>58661514
>>58661848
thank you for posting anime
>>
>>58661893
I think many people who use Python don't program for life.
>>
>>58661848
Is that anime girl a representation of a garbage collector?
>>
This image barely qualifies as an anime image, please choose a more anime-centric image for the next thread. Thank you.
>>
>>58661861
My two main gripes are forced whitespace and the typing system.
>>
>What are you working on, /g/?
Learning opengl for the 7th time.
It's just such a mess.
Surely there were better ways to do this?
>>
>>58661921
It's a wolf girl eating a sandwich
>>
>>58661861
It's easy and convenient, but this causes cancer just like how processed meat gives you cancer. You eat it, it tastes nice and fills you up, but you don't know what the fuck it's made of and what it's gonna do inside you and when you get cancer you won't realise what hit you and can't puke it out in time to save yourself. I think it's just good for quick prototyping and testing, not for production level shit.
>>
File: gc chan.png (28KB, 505x191px) Image search: [Google]
gc chan.png
28KB, 505x191px
>>58661936
This is what happens when you give the wolf girl 800 sandwiches.
>>
File: 146738840786.jpg (95KB, 720x720px) Image search: [Google]
146738840786.jpg
95KB, 720x720px
>>58661925
Do you even know her?
>>
>>58661972
Those yellow ticks are garbage collections.
>>
>>58661973
The anime girl should take up at least 75% of the image space to be an appropriate /dpt/ OP picture.
>>
>>58661933
Try to make something meaningful using it.
Attempting to learn something without a substance will lead you nowhere.
>>
>>58661953
>You eat it, it tastes nice and fills you up, but you don't know what the fuck it's made of and what it's gonna do inside you and when you get cancer you won't realise what hit you and can't puke it out in time to save yourself
So, it's like chicken McNuggets?
>>
>>58661973
>not SICP
she's fake
>>
>>58661994
Anon if you haven't seen all of Haruhi and Azumanga at the very least you don't belong on here.
>>
>>58661994
This is a false flag.

Ignore this poster.
>>
>>58662006
where did i say i don't know who it is
>>
>>58661973
Replace the book she's holding with SICP and you'll have the official permission to start the next anime thread!
>>
>>58662012
You never said who it is so I had to assume you don't
>>
>>58662013
>official permission
You have to go through the proper channels for this anon. You can't just grant it. File a request with the committee and fight them on mailing lists then maybe we can get this image officially sanctioned.
>>
>>58661995
I'l try.
It's just that every time I seem to confuse VBO VAO and all the calls so I'm not getting anywhere it seems.

And then when I'm in other areas the math isn't my strong suit. I'm better at programming systems.

But I'l try. Any ideas on what goal is good to have?
>>
>>58662025
>committee
Huh? I didn't form any kind of committee. You do realize this thread is a dictatorship, right?
>>
>>58662036
And who is the dictator?
>>
>>58662071
Elected by the committee, it's in progress.
>>
>>58662071
Well, technically the provisional government is in charge but I'm fully in control of it. We're switching to a monarchy pretty soon though.
>>58662081
Wrong, elections were banned and you are about to be shot.
>>
>>58662013
Please do, I don't know how to work with graphic editors.
>>
File: anime with see sharp.png (395KB, 720x720px) Image search: [Google]
anime with see sharp.png
395KB, 720x720px
>>58662104
>>
File: 1459376936643.png (118KB, 330x390px) Image search: [Google]
1459376936643.png
118KB, 330x390px
>>58662156
>>
File: pic.png (423KB, 720x720px) Image search: [Google]
pic.png
423KB, 720x720px
>>58662104
>>58662156
>>58662013
I think it's a bit too subtle.
>>
File: anime with see sharp 2.png (454KB, 720x720px) Image search: [Google]
anime with see sharp 2.png
454KB, 720x720px
>>58662166
>>58662185
>>
>>58662195
C# is not programming. >>>/b/
>>
>>58662185
It's fine. The cover is so iconic anyway, so it's still very easy to tell that it's SICP.
>>
>>58661861
Python is amazing if you use it for its intended purpose: a nice scripting language to replace the fuckery that is Perl, or a programming language for very quick development of small programs / simple back end.

In other words, if you don't use it as a replacement for a real programming language, then it's great.
>>
>>58662185
>not the japanese edition
8/10
>>
File: anime with see sharp 3.png (615KB, 720x720px) Image search: [Google]
anime with see sharp 3.png
615KB, 720x720px
>>58662195
>>58662196
>>
>>58662185
It's perfect! It satisfies: >>58661994
>>
>>58662202
>to replace the fuckery that is Perl
Elaborate
>>
>>58661861
It's only good for some math stuff, and then again R is much better at it than Python so there's absolutely no point in learning it or ever unironically using it.
>>
>>58662262
R is hideous to use if you have a programming background.
>>
>>58661933
>Surely there were better ways to do this?
Yes, use Direct3D.
>>
>>58659013

Newer tech doesn't necessarily mean more vulnerabilities, it just means that there are potentially undiscovered vulnerabilities.
>>
>>58662196
Some people have jobs, you know.
>>
>>58662291
>tfw job using C#

At least it isn't Java. It's growing on me, I guess.
>>
>>58662309
>At least it isn't Java.

every single thread.

so what's wrong with Java again?
>>
>>58662309
>It's growing on me, I guess.
That's Microsoft's penis slowly penetrating you, anon.
>>
>>58662284
Newer tech means more hidden backdoors since technology evolved and it's a lot easier (and cheaper) to place some surveillance chip.
>>
>>58662320
>proprietary
>OOP meme
>PublicStaticAbstractDogShitFactories
>only used because big numbers of lines of code required give management the false impression of productivity and make them feel warm and fuzzy inside
>>
GOF > SICP

Prove me wrong.
>>
@58662377
*proves you wrong*
>>
>>58662377
What is GOF?
>>
>>58662395
how did you post this message?
>>
>>58662402
I'm powered with (You)s
>>
>>58662402
Why does that come as a surprise?
>>
>>58662320
Mostly it's the toolsets. I've used Eclipse and IDEA, and neither are even close to VS. Also, I've never needed to bother making a desktop application on Linux, and WPF is so much easier to work with than Swing (again, mostly due to the toolsets).

As far as the actual language goes, there's been a few odd things that I bump up against that feel off, plus I don't care for Java's syntax that mirrors equivalent C# features (like LINQ). I don't know if Java has extension methods yet, but those really help the readability of code when used appropriately.

Personally, Java was my first language, so I was "used to it" first, but the entire dev process for C# stuff (desktop applications, backend data integrations, mobile apps) feels so much easier.
>>
>>58662395

Current state of /g/, everyone.
>>
>>58662228
Come on now. There's a reason even 100-year-old old school wizards are migrating from Perl to Python despite having used Perl for their entire lifes. Python just does everything that Perl does in a much simpler manner.

>You can learn Python in 1 or 2 hours to the point where you can write very complicated scripts with it.
>Perl is a huge language comparatively, has a very peculiar syntax and a much higher learning curve.

>Python code looks like pseudocode, any programmer can easily read and understand what it does even if he doesn't know Python.
>Perl on the other hand... well, suffices to say that it's one of the most popular languages in Obfuscated Code contests.

The list goes on. I love Perl but Python just renders it completely useless.
>>
>>58662414
Posting a message to the internet without having access to the internet is pretty weird
>>
>>58662424
Who are you quoting? I want to read the full list.
>>
>>58662424
How does it feel being a double-digit? Does it hurt?
>>
>>58662413
When someone says your post number but doesn't correctly link it does it give you less power or way more power?

I always thought doing that kind of (you) denial was like giving someone like 100 (you)s because it takes more effort to go out of your way to be petty about it.
>>
>>58662457
Myself. If you want more reasons then STFW, the topic of Perl vs. Python and why Python is better has already been discussed endlessly.
>>
>>58662337
Nice paranoia, faggot.
>>
>>58662472
(You) is a treated like a legitimate currency despite the inflation it has suffered. Anything else isn't even thought of as currency so it's entirely worthless
>it takes more effort
it's just two more actions which are worth it in the end.
>>
>>58662507
What's the point of this shitpost?
>>
>>58662513
What kind of stupid question is this?
>>
>>58662522
Is this a new meme?
>>
File: 山東饅頭.jpg (823KB, 4255x3465px) Image search: [Google]
山東饅頭.jpg
823KB, 4255x3465px
>>58662535
no this is
>>
>>58662535
Please return to /b/ where you belong.
>>
>>58662542
That looks delicious.

Is it as soft as it looks?
>>
>>58662542
>>58662577
Looks like another overly smooth and gelatinous nip food.
>>
File: part7_img.jpg (50KB, 300x440px) Image search: [Google]
part7_img.jpg
50KB, 300x440px
>>58662577
They're steamed buns, they're very soft and doughy.

It's a very standard dough recipe with the addition of some sugar. If you're a texture person like me they're lovely.

You can make them youself if you have a steamer (you can get a bamboo one for about $15) or find somewhere that sells them. Those kind are called mantou
>>
>>58661571
trash
>>
This is homework, but I will post it here anyway.
I am supposed to make a program with 2 for loops in which the user is asked for a number of rows and columns. It's supposed to draw a picture with dots, stars and spaces, however I feel I'm doing something wrong, since even though the random generator should be random, I get a lot of repeating symbols.

for (int row = 0; row < rows; row++)
{
int pic = r.Next(3);
if (pic == 0)
Console.WriteLine(" ");
else if (pic == 1)
Console.WriteLine("*");
else Console.WriteLine(".");
for (int col = 0; col < column; col++)
{

if (pic == 0)
Console.Write(" ");
else if (pic == 1)
Console.Write("*");
else Console.Write(".");
}
}
>>
>>58661861
not lisp
>>
I keep oscillating between "I'm smart, I can handle C++!" and "What the hell, why would Bjarne do that?" in my mind.

I miss having fun programming. Should I keep fighting with C++, or fuck off to Java and 'just like make game' like I used to do, back in the good days.
>>
>>58662622
see
>>58662196
>>
>>58662622
Also I forgot to add in the random generator since I was translating. There should be another
pic = r.Next(3); in the second for loop.
>>
>have to present in class
>live coding with my screen projected on the board
>always use "nigger" as a variable name when I can't think of one
>accidentally make a variable called nigger in front of the entire class
>there were black students in the class
How do I kill myself?
>>
>>58662220
>herb schildt
>>
>>58662643
Yes abandon C++. There's really no point in using it unless you're aiming for the high end of performance. In which case you're wasting your time with C++ features anyway.
>>
>>58662655
>black students
thank you for not writing "black people"
>>
File: anal beads.png (19KB, 675x465px) Image search: [Google]
anal beads.png
19KB, 675x465px
>>58662622
>>58662649
Looks about right to me.

What exactly is the program supposed to do?
>>
>>58662377
LoL > *
>>
>>58662655
Depending on how long it was on the board, you might not have to kill yourself.
>>
>>58662679
>>>/v/
>>
>>58662622
Maybe for now try and structure your problem on paper? You haven't described this for us well but judging from how "draw something based on input" assignments tend to be you haven't thought it through properly.
>>58662377
>>58662679
I have never heard of either of these books.
>>
>>58662676
Ask for user input and print a random picture with those symbols. I think my code is wrong, since if I enter 1 and 1, it prints the symbols in 1 column and 2 rows. If it's 2 and 2, you get 3 columns, 3 rows.
>>
>>58662698
let over lambda
>>
>>58662714
I mean user input is number of rows and number of columns.
>>
>>58662714
Easy, just bump your initial counter on each loop by one and you're sorted.

Also, move the row loop before the column's writeline so you're not leading with a character by itself.

var rows = 3; // user input here
var columns = 3; // user input here
var r = new Random();

for (int row = 1; row < rows; row++)
{
int pic = r.Next(3);
for (int col = 1; col < columns; col++)
{

if (pic == 0)
Console.Write(" ");
else if (pic == 1)
Console.Write("*");
else Console.Write(".");
pic = r.Next(3);
}
if (pic == 0)
Console.WriteLine(" ");
else if (pic == 1)
Console.WriteLine("*");
else Console.WriteLine(".");
}


Also, I'm going to rewrite this to be more aesthetically pleasing.
>>
>>58662714
try filling a column and then newline
for x from a to b
for y from c to d
//your if/write statements here
//end y loop
//newline here
//end x loop
>>
>>58662669
Thanks, that helps. Hopefully I can program for now on without worrying about languages. Switching back an forth is a really bad habit..
>>
>>58662769
*row, not column
>>
File: I'mdumb.png (31KB, 800x491px) Image search: [Google]
I'mdumb.png
31KB, 800x491px
Sup /dpt/, I’ve finally started my journey into programming with C++. But I’ve hit my first snag.
I got to ampersand (&), and I’m a bit confused as to how it works.

For example, in pic related.
My understanding is that the difference between not using ampersand (scenario 1), and using ampersand (scenario 2), is:

scenario 1: the value "1" is copied to another place in RAM and then used by later functions.

scenario 2: the original value "1" is referred to directly by the function.

Which sounds ok until I get to the conclusion
>In scenario 1 the variables would not be passed by reference, but by value, creating instead copies of their values. In this case, the output of the program would have been the values of x, y, and z without being modified (i.e., 1, 3, and 7).
Why would the output of x be 1, in scenario 1? Why would the function not work on it just because it's a copy rather than the original?

Code:
// passing parameters by reference
#include <iostream>
using namespace std;

void duplicate (int& a, int& b, int& c)
{
a*=2;
b*=2;
c*=2;
}

int main ()
{
int x=1, y=3, z=7;
duplicate (x, y, z);
cout << "x=" << x << ", y=" << y << ", z=" << z;
return 0;
}
>>
>>58662802
if i wrote a 1 on a piece of paper, photocopied it, then scratched out the 1 on the copy and replaced it with a 2, what is number on the original paper?
>>
>>58662802
>Why would the function not work on it just because it's a copy rather than the original?
Because it's a copy and not the original.
>>
>>58662744
This still doesn't work, if you set the rows and columns to 1 or 2.

>>58662769
There's already WriteLine in the second loop, that bumps the characters into a new line.
>>
>>58662854
>>58662894

I get that the original paper remains 1. (As I show in scenario 1 in pic). But when you do cout << x, why is it that it refers to the original rather than the copy that got modified by the function "duplicate"?

Does cout << x always refer to the original and never the copy? (This is what I'm confused about)

Because then what would be the point of
>scenario 1: the value "1" is copied to another place in RAM and then used by later functions.
What's the point of using the copy in the function when you want to output it, you get the original anyway? Why would you even ever consider scenario 1 whatsoever?
>>
If Java has a garbage collector, why doesn't it collect itself???
>>
>>58662802
#include <iostream>
using namespace std;

void increment(int a)
{
//At this point we have a copy of whatever we passed to the function.
a=a+1; //This increments a for within the function so when we do
cout<<"a inside increment(int)\n";
//The local variable is modified.
}
void incrementRef(int& a)
{
//At this point we have a reference to whatever was passed to the function
a=a+1;
//This modifies the value that's outside the function, a is just a 'pointer' under the hood. It's a value that points to another value, when we do something with it we affect the original value. There's no copy.
cout<<"a inside incrementRef(int&)\n";
}
int main ()
{
int x=1;
increment(x);
cout << "Outside function before incrementRef(x): x=" << x<< "\n";
incrementRef(x);
cout << "Outside function after incrementRef(x): x=" << x << "\n";
return 0;
}


Also if you ever hear about pointers they're really the same thing except syntax is different. At least to a rookie.


Also I dunno what that image is illustrating exactly, it's a bit confusing to me.
>>
>>58662942
>
cout<<"a inside increment(int)\n";

God. I forgot to add the variable
#include <iostream>
using namespace std;

void increment(int a)
{
//At this point we have a copy of whatever we passed to the function.
a=a+1; //This increments a for within the function so when we do
cout<<"a inside increment(int)"<<a<<"\n";
//The local variable is modified.
}
void incrementRef(int& a)
{
//At this point we have a reference to whatever was passed to the function
a=a+1;
//This modifies the value that's outside the function, a is just a 'pointer' under the hood. It's a value that points to another value, when we do something with it we affect the original value. There's no copy.
cout<<"a inside incrementRef(int&)"<<a<<"\n";
}
int main ()
{
int x=1;
increment(x);
cout << "Outside function before incrementRef(x): x=" << x<< "\n";
incrementRef(x);
cout << "Outside function after incrementRef(x): x=" << x << "\n";
return 0;
}
>>
>>58662919
The garbage collector is garbage
>>
>>58662954
And now you forgot you can't use the code tag twice. Epic fail.
>>
>>58662970
>Epic
Indeed.
>can't use the code tag twice
No you can do that. I just didn't copy the code tags (keep forgetting that 4chanx quotes with the code tags when you select and reply. Ctrl+c doesn't do that).
>>
>>58662914
Okay, I got it now, thanks for the help, it's supposed to look like this.

for (int row = 0; row < rows; row++)
{
int pic = r.Next(3);
for (int col = 0; col < columns; col++)
{

if (pic == 0)
Console.Write(" ");
else if (pic == 1)
Console.Write("*");
else Console.Write(".");
pic = r.Next(3);
}
Console.WriteLine();


If anyone knows how to make it different or better, or if I made any mistakes, I'd appreciate comments.
>>
>>58662914
? Did you make another post? I just see Write in the inner loop of your original post and the WriteLine in the outer.
>>
>>58662914
>>58663032
Disregard, I see you solved it.
>>
>>58662915
>>58662915
>But when you do cout << x, why is it that it refers to the original rather than the copy that got modified by the function "duplicate"?
When you call the
duplicate(x, y, z)
(defined without &) it copies (x, y, z) to (a, b, c) and uses those *copied* values for its own purposes.
Those copies are only valid inside that function.
And you ran cout<<x inside the main() function, not duplicate().
>>
File: anal beads.png (26KB, 833x345px) Image search: [Google]
anal beads.png
26KB, 833x345px
>>58663032
>If anyone knows how to make it different or better, or if I made any mistakes, I'd appreciate comments.
You're fine considering this is supposed to be using traditional "for" loops and homework.

Personally, I'd have a little fun with it and do something like this:
Write("Enter a number of rows: ");
int rows = int.Parse(ReadLine());
Write("Enter a number of columns: ");
int columns = int.Parse(ReadLine());
WriteLine(Concat(Range(1, rows)
.Select(row => Concat(Range(0, columns)
.Select(col => characters.PickRandom())) + Environment.NewLine)));


Obviously, you could utilize
int.TryParse()
to handle cases where your uses may decide to enter "cat" or a number that's too large.
>>
>>58663132
This is for C#, just pasted the code in it and it doesn't work. Should I be enabling using.something?
>>
>>58663046
Ah, ok. That makes perfect sense. So it wasn't that I -can't- output "2" rather than "1", but I just can't output "2" from main (). I can output from duplicate (), if i stuck cout << x in there?

So pass by reference allows me to create a local copy that is -only- valid within the function to which it is copied to. You can only output the modified value within the brackets of that function.

In turn, pass by value changes the original, therefore the change can be observed globally no matter where you try to output it.
>>
>>58663301
Shit, I got it backwards.

I mean pass by reference allows me to mess with original and pass by value messes with the local copy.
>>
File: 21.png (34KB, 271x173px) Image search: [Google]
21.png
34KB, 271x173px
How do I make my compiler output this with only one for loop and one statement?
>>
>>58663344
>my compiler output
What
>>
>>58663295
A few things, yeah.

You'll need the following in your header:
using static System.Console;
using static System.Linq.Enumerable;
using static System.String;


This isn't best-practice, but they can make your life more convenient if you're prototyping something.

This is because we're using the following:
Console.WriteLine()
Console.Write()
string.Concat()
Enumerable.Range()


Also, I've got extension methods that grabs a random object(s) from an enumerable:
public static T PickRandom<T>(this IEnumerable<T> source)
{
return source.PickRandom(1).Single();
}

public static IEnumerable<T> PickRandom<T>(this IEnumerable<T> source, int count)
{
return source.Shuffle().Take(count);
}

public static IEnumerable<T> Shuffle<T>(this IEnumerable<T> source)
{
return source.OrderBy(x => Guid.NewGuid());
}


Again, this is scrappy programming, but for simple stuff it isn't really a big deal.
>>
>>58663374
I meant how do I make it output in console with only one for loop and one statement?
Sorry, long day, I'm tired and can barely think.
>>
>>58663344
>and one statement?
but you need to iterate two things, as well as print, I don't understand the constraints.
>>
>>58663504
lambdas, son
>>
>>58663404
What language are we talking about?
You must read about formats in print statement, there must be a format with the output tied to the right side.
>>
>>58663510
Figured they weren't "allowed" because this seemed like an early test.
>>
>>58663504
One statement inside the for loop. Again, I'm sorry.
You can put most iterations in the print, or you can declare out of the loop.
>>
File: screenFetch-2017-01-26_10-18-26.png (49KB, 1920x1080px) Image search: [Google]
screenFetch-2017-01-26_10-18-26.png
49KB, 1920x1080px
>>58661514
>>
>>58663510
How?
>>
>>58663555
>You can put most iterations in the print
That's messy code for the sake of minimalism.
>>
>>58663555
Okay, hopefully last post explaining because I'm really tired. Basically you need to write as few lines as possible, preferably only one in the loop, to make the console output that statement.
It has to calculate it, you can't just print it.
>>
>>58663555
It depends on the language. But you are going to need a print statement and a statement to update the loop state. I don't think what you want is possible (depending upon the language of course).
>>
>>58662202
>simple back end.
why is it such a big part of linuxes now?
you stupid prick
>>
>>58663575
Depends on the language, obviously.
>>
>>58663592
>>58663577
Let's say C#, for the record, I don't count for loops as statements, even though they could be. I mean the things inside the brackets, or whatever, I'm not sure how they're called. The condition?
>>
>>58663606
any non-pleb language with lambdas.
>>
>>58663583
easiest way I can think of...
local t = {}
for i = 1, 9 do
t[#t+1] = i
print(table.concat(t).." * 9 + "..tostring(i+1).."= "..tostring(tonumber(table.concat(t))*9+i+1))
end
>>
>>58663617
>Let's say C#
OK
https://msdn.microsoft.com/en-us/library/system.string.format%28v=vs.110%29.aspx
>>
>>58663669
You have to calculate it, not use strings. Otherwise this is pointless.
>>
>>58663680
I don't understand, what's the problem?
If you want to make pretty output, you are supposed to work with strings, no?
>>
>>58663680
Jesus Christ, anon
>>
>>58663652
Or in C..
int acc = 0;
for (int i = 1; i < 10; i++) {
acc = acc*10 + i;
printf("%d * 9 + %d = %d\n", acc, i+1, acc*9+i+1);
}

You *could put the 'acc = acc*10 + i' line in the loop statement and start the loop at 2, but it becomes undefined behavior at that point because there is no order of evaluation of comma separated statements.
>>
>>58663696
Oh shit, I just realized.
int acc = 1;
for (int i = 1; i++ < 9; acc = acc*10 + i) {
printf("%d * 9 + %d = %d\n", acc, i, acc*9+i);
}
>>
>>58663725
That's not centered though.
>>
>>58663754
Learn your printf specifiers then. It's easy enough.
>>
have any of you had experience in programming AI? which language do you think are the most common when it comes to AI programming in industry?
>>
Idiot working on a game here.

I have a bunch of combat unit classes. Each unit type does a particular amount of base damage to another unit type.
private float _vsSoldier = 55;
private float _vsTank = 10;
// etc


I have a BattleCalculator class that executes a damage formula and takes an attacking unit and a defending unit as parameters. How can I have my BattleCalculator automatically set the damage amount based on the unit types without a million if or switch statements? There will eventually be a lot of combinations. Solider vs MachineGunner, Tank vs MachineGunner, Anti-Air vs Plane, etc.

I feel like the solution is obvious but it's just not coming to me.
>>
Hey guys I'm taking a C++ programming class this semester. I've dabbled a bit in other languages, mainly java. Think by the end of this semester I can land a programming job that will get me through the rest of my schooling?
>>
File: anal beads.png (11KB, 827x147px) Image search: [Google]
anal beads.png
11KB, 827x147px
>>58663344
>>58663617
>C#
for(int ayylmao = 0; ayylmao == 0; ayylmao++)
{
WriteLine(Concat(Range(1, input).Select(x => $"{Concat(Range(1, x))} x 9 + {x + 1} = {new string(1.ToString()[0], x + 1)}" + Environment.NewLine)));
}


The loop only runs once because fuck the police. Close enough, I hope.
>>
>>58663811
>
 WriteLine(Concat(Range(1, input).Select(x => $"{Concat(Range(1, x))} x 9 + {x + 1} = {new string(1.ToString()[0], x + 1)}" + Environment.NewLine)));

C# was a mistake
>>
>>58663807
i've applied for about 20 internships this year (i'm an undergrad looking for work to complete between my second and third years of study) and the main three that employers seem to be looking for are C++, C# and Java
>>
>>58663806
Make some method to every combat unit class, which outputs the value of damage, given the attacker's class.
>>
>>58663780
No, fuck you.
>>
File: das32.png (8KB, 642x98px) Image search: [Google]
das32.png
8KB, 642x98px
>>58663725
>>58663696
This does not work correctly if typed in C#.
>>
>>58663790
That's one place where python is used extensively.
>>
has someone here used libFirm before?
>>
>>58663869
hello fellow D friend.
>>
>>58663874

>>58663669
>>
>>58663839
But do you think a semester course would be enough? It already seems not too difficult since I was familiar with Java, but I was also still noon with java.

Like how good do I have to be to be qualified for entry level programming jobs?
>>
File: dsad325.png (6KB, 665x102px) Image search: [Google]
dsad325.png
6KB, 665x102px
>>58663874
>>58663890
Okay, fixed it, looks like this.
How the fuck do I make it look pretty now?
>>
>>58663943
>arbitrary constraints one how you can write it
>pretty
>>
>>58663943
>fixed it, two lines
what teh fuck men
>>
>>58663943
You have two statements in your for loop, shithead.

You'll have to replace the rez with its assignment in the second statement.
>>
>>58663899
if you have a good understanding of computer architecture then C++ isn't so difficult. as far as i can tell, companies employing new graduates are looking for a good attitude rather than a person that knows a lot, so if you do well in your course it might not matter what you actually know. even if the C++ you learn now isn't enough, it seems like a language that you will need eventually so i think it sounds like it would be worth your time.
>>
>>58663869
Or even...
>>
>>58663943
>>58663725
>>58664036
Doesn't meet the requirements.

One for loop, and one statement.
>>
>>58663320
Patrician in the making
>Find "programming in Ada 2012" in libgen.io
This will be your how to. You know other languages so you won't be lost and he goes into a lot of detail on why AND how to do something.
>http://www.ada-auth.org/standards/12rm/html/RM-0-4.html
Skim the standard. You'll find a couple gems the book didn't cover.

Other than that Google and the wikibooks for quick questions and examples.
>>
>>58664055
All others also contain statements as parameters to the printf function (i.e. "acc * 9 + i"). The entire wording is bullshit.
>>
>>58663344
What's the haskell solution?
>>
>>58664055
for(int x = 1; x <= 8; x++)
{
Console.WriteLine($"{string.Concat(Enumerable.Range(1, x))} x 9 + {x} = {new string((char)(1+48), x)}");
}
>>
>>58663344

Piece of cake:

for c in 1..7 do
c.times do |i|
print i+1
end
print " x 9 + #{c+1} = "
(c+1).times do
print 1
end
puts
end
>>
>>58664099
Haskell doesn't provide solutions, only smug ways of demonstrating your virginity.
>>
>>58664096
>The entire wording is bullshit.
There certainly ain't enough information, but it is very clear in that you're to use a for loop, and one statement.

An appropriate assumption would be that it can exist within a method, and maybe that method accepts a parameter that determines to what extent the statements are printed.

However, using more than one statement in order to declare variables is clearly against the requirements.
>>
>>58664124
How can a language "provide solutions"?
>>
> "See, my 'print' is called 'print' and C++'s is 'printf' and... whatever... C's I should say. C++ has an ungodly mess."
- Jonathan Blow
>>
>>58664183
https://youtu.be/9QE-z0aQheU?t=41m34s
>>
>>58663953
>>58663957
>>58663968
>>58664103
With my knowledge, I don't know how to do it otherwise. This is as good as I can make it.
And I still don't know how to make it like a pyramid (the = in the middle) without fucking up everything.
>>
>>58664263
Fucking study your language.
>>
>>58664297
I'm a beginner, I know the basics.
I could use \t, but that will only push everything to the right, not make it center aligned. With two for loops you could do it, but I don't know how to do it with one.
>>
>>58664263
Learn C#, mang.

Easy peasy, add a PadLeft to that bitch:
for(int x = 1; x <= 8; x++)
{
Console.WriteLine($"{string.Concat(Enumerable.Range(1, x)).PadLeft(8)} x 9 + {x} = {new string((char)(1+48), x)}");
}
>>
File: anal beads.png (10KB, 1035x141px) Image search: [Google]
anal beads.png
10KB, 1035x141px
>>58664322
>>58664320
>>
>>58664117
FTFY:
for c in 1..7 do
print ' '*(7-c)
c.times do |i|
print i+1
end
print " x 9 + #{c+1} = "
puts '1'*(c+1)
end
>>
How to get better in programming /g/? I've been programming for about 3 years now, last year semi consistently and I've done some impressive (to my level) web apps with different languages. Now I'm in a spot where I don't know what to learn/do/read next. I love reading books and I've read Pragmatic Programmer and now finishing Clean Code and some other minor books. Tell me /g/ where to go next.

And I'd be glad to have another answer than program more, I already do that. Maybe this is a question about books then dunno.
>>
>>58664360
You've been programming for 3 years and you don't have a job that provides goals to work towards and pays you for the skills you surely have by now?
>>
>>58664376
I'm still at school and I got hired for the summer. First programming related job tho. Maybe I just wait for that and they will point me in the right direction.
>>
After reading https://e.xtendo.org/monad, I'm starting to think if I should drop learning Racket and continue with Haskell. The thing is, I really like the Racket syntax. What should I do senpaitachi?
>>
>>58664441
Develop Hasket.
>>
/dpt/ threads nowadays are basically
>calling out dumb animeposters
>shitting on each others language of choice
>shilling meme languages
>insulting each other over non-issues

And no, I don't want to contribute anything myself.
Fuck you.
>>
@58664539
>>>/r/ibbit
>>
>>58664539
I'm sure you could contribute a lot Anon-kun
>>
>>58664539
You forgot
>meta shitposting
Don't worry, you fit right in!
>>
>>58664539
So what you're saying is we're posting about:
>thread culture
>discussing various programming languages
>showing anons our favorite language
>stimulating discussion by ironically pointing out asinine mistakes and quirks

Sounds fine to me.

Also, (You).
>>
>>58664539
Who are you quoting? I want to read the full list.
>>
Is the "Automate the boring stuff" book for python recommended? Going through it now and it seems pretty slow.
>>
>>58664582
>Automate the boring stuff is a boring book
heh
>>
>>58664539
You know you're here forever, no matter what happens.
>>
I want to learn to code, where do I start?
>>
>>58664539
Mods completely raped anti-anime posters yesterday. Felt good.
>>
>>58664539
Rust is not a meme language though
>>
>>58663943
So how do I make this into a pyramid with another for loop?
>>
>>58664609
dumb frog poster
>>
>>58664594
wrong. i'm closing this tab right now (forever)
>>
>>58664593
Is there a book I can check out that will auto mate this boring book?


kindly advise
>>
>>58664624
no, you didn't
>>
>>58664632
Hey, it's his friend. He closed it.
>>
>>58664582
Do you know how to program already?
>No
Yes, it is. Far superior to Zed Shaw's trash. Get you an academic Python book to supplement it; I always recommend one by either John Zelle or John Guttag.
>Yes
Why the fuck are you using Automate the Boring Stuff and not LearnXinY?
>>
>>58664634
fuck you twice frog poster
>>
>>58664594
I mostly frequent /pol/ and /x/, so that's OK.
I prefer lain, the problem is it's very slow.
>>
File: 1467054649374.png (336KB, 804x900px) Image search: [Google]
1467054649374.png
336KB, 804x900px
>>58664634
I hope frogposting never dies 2bh
>>
>stand up to go to bathroom, make coffee, whatever
>"oh man i want to program"
>"my will is filled with motivation"
>sit back down
>nah i dont want to program anymore

does this have a cure
>>
>>58664603
Start by using this beginner book for my favorite programming language, and I'll not even ask you what your motivations for programming are in order to recommend a good first language.
>>
>>58664674
wear knee socks
>>
File: bed jampu.webm (2MB, 1024x576px) Image search: [Google]
bed jampu.webm
2MB, 1024x576px
>>58664692
perv
kannas are for parenting
>>
>>58664671
>I prefer lain, the problem is it's very slow.
is it still infested with leftist "free"tards?
>>
>>58664671
>>>/global/rules/2
>>
>>58664659
I wouldn't say I know how to program but I've "dabbled" over the last few years. I currently work in IT.


I've completed the first part of the Java mooc on that helsinki site, all of the free stuff on codeacademy, and the front end and basic algorithms on FCC. I also did that intro to programming lynda course.


What's XinY?
>>
>>58664712
>>
File: 43058490287.png (81KB, 250x250px) Image search: [Google]
43058490287.png
81KB, 250x250px
>>58664692
That's one thicc dragon loli
>>
>>58664748
For you...
>>
File: 1485383536295.png (196KB, 607x805px) Image search: [Google]
1485383536295.png
196KB, 607x805px
>>58664748
>>
>>58662942
Not OP, but also learning C++ right now.

You stated things very clearly. Thank you.
>>
>>58664821
Gonna need a sauce bruh
>>
>>58664738
>but I've "dabbled" over the last few years
Stick with Automate the Boring Stuff and get a supporting academic textbook to consult. Almost all public/light paywall MOOCs so far (good acronym, should be courses for mooks) don't really teach for understanding, they're pajeet factories that don't get into the nitty-gritty that you need to understand. Automate the Boring Stuff is probably one of the few courses/books that tackles teaching syntax AND gives it as much context as possible.

I think the only MOOC system that isn't a scam or letdown is Pluralsight, in all seriousness. I had it for college and I used it once or twice and it was pretty good; I got free access again recently because I'm already going back and if I had a bigger paycheck, I'd pay for it without hesitation. Most of the courses are really well taught and are taught by people who have been around the block.
>>
oh and
>What's XinY?
Google it. It's useful if you already know how to program but it goes over any given language's syntax.
>>
>>58664873
I stole it from /a/. It's from the manga: Kobayashi-san Chi no Maid Dragon. There's also an anime currently airing from Kyoani. The protagonist is a female code monkey writing Python.
>>
In Java, I'd like to import a package one module of my project but not in the rest. For example, in the memes.data package, I'd like to have access to guava but I dont want guava to be accessible in memes.persist package. Is this possible in Java or another language?
>>
>>58664893
>not actually a doujin

Damn my life, gonna go learn scala to punish myself
>>
>>58664923
http://gelbooru.com/index.php?page=post&s=list&tags=kanna_kamui
It's programming related. I swear :D
>>
>>58664876
>>58664889
>google it
expected that I guess


Thanks for the info! I'll stick with the book for now, I'm really looking to take this to the next level. I've always started learning, and then quit after I couldn't do something more difficult than basic programs.
>>
>>58664945
Well you need programming to make a booru I imagine
>>
>>58664674
Yes, it's called discipline. Motivation can give you an occasional boost, but relying solely on it will surely become your undoing.
>>
>>58661995
Is there a way to generate a nice waveform by passing the shader only a couple of samples of the sound you're playing and not proper polygons?
>>
>>58664905
You can only do that if you make that part of your code into a library.
>>
>>58661514

anyone else think this gif is really gay?
>>
>>58665140
Only a gay person could think that
>>
What book to learn C++ for beginners ?
>>
>>58665040
where does one acquire this "disacipline"?
>>
>>58661514
guys I have a question I could not google.
how does linux or say grub for that matter display text before any kind of graphics driver is loaded ?

or am I misunderstanding things here ?

like grub can display images now and uefi can do all kinds of whacky shit

can someone clear this up for me ?
>>
>>58665296
>>>/g/sqt
>>
File: sepples4kids.jpg (68KB, 720x960px) Image search: [Google]
sepples4kids.jpg
68KB, 720x960px
>>58665201
>>
>>58665376
That explains the high suicide rates among kids.
>>
>>58665376
You sick fuck what are you doing to those children?
>>
>>58665201
youll never finish a book, just use http://www.learncpp.com/
>>
>>58665395
it could be worse,
think writing C without the standard library
>>
>>58665395
At least it's CPP and not just CP
>>
>wrote program where everything is encapsulated
>nothing sees any information that it doesnt
>decide to tweak it so a core function needs an extra parameter
>have to pass that parameter all the way down to the function
>changing code everywhere to fix this
WHY CANT EVERYTHING BE GLOBAL

DAMN YOU OOP
>>
>>58665493
>WHY CANT EVERYTHING BE GLOBAL
Work on a non-trivial project and you'll understand.
>>
>>58665493
That's not really just an OOP issue
>>
>>58665493
You shouldn't have global mutable state but you also shouldn't use OOP :)
>>
>>58665509
wrong
>>
>>58665535
explain
>>
>>58665551
it is almost entirely an OOP issue
>>
>>58665471
>writing C without the standard library
>worse
I'm pretty sure you meant "better".
>>
>>58665588
explain
>>
>>58665588
No, it's an architecture issue. You'd never have that issue if you followed SOLID and GRASP.
>>
>>58665588

git gud at OOP and you wouldn't have this problem
>>
>>58665605
>>58665613
>>58665614

wrong

OOP encourages you to use more mutable state all the while hiding parts of it and creating a hideous frankenstein's interface, which is the problem

the solution is either use less mutable state or stop hiding it only to bend over backwards to try and reach your shoe because bending forwards is a protected member of the bender superclass
>>
Hey, Junior on college here with pretty decent Java skills (including some Android), some php, JS, html, css, c#, mysql as well. Money is a bit tight, I want to make some money in my free time doing free lancing.

What is the most marketable skill to offer on freelance websites right now? I'm not much into front end, especially designing, but I will learn and do whatever's necessary.
>>
>>58665672
>OOP encourages you to create a hideous frankenstein's interface
Wow, you suck at architecture and you have no fucking clue what OOP is about. How does it feel being a double digit?
>>
>>58665700
It's probably the same guy who thought that using structs in C is OOP.
>>
>>58665672
>the solution is either use less mutable state or stop hiding it only to bend over backwards to try and reach your shoe because bending forwards is a protected member of the bender superclass
Or maybe - just maybe - you start using your brain and stop tightly coupling your structure, you fucking moron.

Don't be STUPID: http://williamdurand.fr/2013/07/30/from-stupid-to-solid-code/
>>
>>58665700
>>58665728
>>58665731
Sure is OOP tonight.
Where have all the real posters gone, pajeet, ramir and dangesh?
>>
>>58665736
Sure is 17 yo edgy "haxxorrz" who has absolutely no software engineering experience in here.
>>
>>58665731
>stop tightly coupling your structure
You mean stop using OOP?
I already did that

>>58665700
OOP is about thinking in terms of objects.
This is really retarded when you want to do extremely abstract shit and it leads to bullshit like AbstractBeanFactoryFactoryImplementorManagerClass, which is ABSOLUTELY the logical conclusion of OOP, despite your inevitable reply "t-that's just Java!", because you obviously use some other language that's mostly a mix of procedural and functional with concepts from PLT, and not an actual language based largely on the retarded idea that is OOP
>>
>>58665672
>OOP encourages you to use more mutable state
Not really, have you ever heard of the single responsibility principle? Classes should have only one reason to change. Git gud and stop blaming abstract paradigms for your failures.
>>
>>58665748
Nah, just a troll. The second part of >>58665758 is nearly a direct pasta from a post a few threads back.
Lurk more, I guess.
>>
File: wtf-am-i-reading.jpg (41KB, 409x425px) Image search: [Google]
wtf-am-i-reading.jpg
41KB, 409x425px
>>58665758
>OOP is about thinking in terms of objects.
Current state of /g/, everyone.
>>
>>58665758

>bullshit like AbstractBeanFactoryFactoryImplementorManagerClass

Look, son, a strawman!
>>
>>58665775
>>OOP encourages you to use more mutable state
>Not really
OOP is fundamentally based on an intuitive notion of objects.
That is the core principle from which every other decision comes
Objects change.

>>58665778
>The second part of >>58665758 (You) is nearly a direct pasta
You literally made that up you fucking liar.

>>58665799
>a strawman
Take some pride in your fucking paradigm man, or do you just know too well what trash real OOP actually is?
>>
>>58665808
Are you a female?

Before you found out about 4chan, what did you use to do to embarrass yourself in public?

The error you described here >>58665493 is the result of such a crass anti-pattern that it is laughable. I teach fucking sophomores how to avoid that.
>>
>>58665839
That's not me.
>>
>>58665680
>pls respond
>>
I recently got interested in contributing to OSS. Which projects do you contribute (have you contributed) to? Where did you start?
>>
>>58665839
Oh, and the anti-pattern you're describing

it's OOP, isn't it?

it's pretty easy to avoid
>>
>>58665808
>You literally made that up you fucking liar.
Should I have figuratively made that up?
>>
>>58665870

Do yourself a favour and do avoid it, my dude.

If you can't fly an airplane without crashing it, you shouldn't.

Stick to your bicycles.
>>
>>58665672

perhaps your program doesn't even need OOP. The argument isn't whether you suck at OOP or not, it's just you or whoever it was that decided to use OOP made a bad decision. OOP is great....for like rpg vidya games and shit....
>>
>>58665864
Learn fucking Wordpress and start doing some freelance theme development and shit.
>>
>>58665872


>>58665889
OOP is like a helicopter with a single main rotor and no tail rotor
>>
>>58665907
Shut up, you don't even know what Liskov substitution is - you think OOP is "structs with functions XDDDD".
>>
>>58665925
No I don't
when did I say that?
I know full well OOP isn't structs with functions
>>
>>58665898
He obviously sucks though. His design is fundamentally flawed if he needs to pass a parameter all the way deep down to his back-end.
>>
>>58665925
Inheritance fundamentally breaks Liskov substitution. Without inheritance, you're just using interfaces, in which case that's pure subtyping with dynamic dispatch and isn't an OOP-specific thing.
>>
I'm going to try and relearn C by going through the MIT algorithms book and doing all of the examples/problems with C.

Is there a better way?
>>
>>58665939
Deep inheritance is an anti-pattern, you fucking idiot. Favor composition over inheritance. God, you just keep digging yourself deeper! Do yourself a favor and stop posting, lest you embarrass yourself further!
>>
>>58665935

I don't know what he did, but sounds from his description that it was a leaky abstraction. Blaming OOP for that is such a first-timer thing.
>>
>>58665935
It's not my design, I've told you this, I'm not the guy who posted the problem
>>
>>58665935

ya im assuming his inheriting is fucked or what?
>>
>>58665963
The point is OOP without inheritance might as well not be OOP. And this is my first post in the "discussion".

OOP as a thought process (designing software as objects that interact by passing messages) fundamentally requires mutation as well, to get back to the original thing. If you're not doing that, you again might as well think in functional terms instead of a weird hybrid of OO and imperative.
>>
>>58665963
>God, you just keep digging yourself deeper!
I'm the guy you wrongly thought >>58665963 is

>use composition not inheritance
This is fucking hilarious
What happened to Linkov substitution or whatever?

Or are you gonna claim row polymorphism is an OOP thing too?
>>
What's with the object orientation hate meme on /g/?

Why don't those people just go work developing all those big ERPs developed in functional languages like for instance... oops, there's none!
>>
>>58665987
because OOP is fucking dumb

>functional programming is the only alternative to OOP
>>
>>58665981

Objects passing messages is just syntactical sugar to help implement what OOP really is about. Listen to this series of lectures, kid:

http://www.youtube.com/watch?v=i5-hLrN0Shc
>>
>>58665904
Does that mean I should create some theme and sell it or that I should find people who need a website and just use existing Wordpress theme and customize it for their needs?

Also, is react worth learning as a newbie freelancer?
>>
>>58665997
>because OOP is fucking dumb
Spoke like a true 12 year old, as expected from /dpt/.
>>
>>58665997

I want this meme to end.
>>
File: 1456125439222.jpg (302KB, 1440x810px) Image search: [Google]
1456125439222.jpg
302KB, 1440x810px
>>58665974
>>
>>58666032
It can't end, because OOP is popular.

The denizens of /dpt/ have to have something to feel smug about, and relentlessly berating OOP is the path of least resistance.
>>
>>58666019
>design patterns
AKA OO gymnastics
>how can you solve this using inheritance?
>>why do i need to use inheritance?
>SHUT UP YOU DIRTY FP 12 YEAR OLD ILL KILL U
>>
>>58666019
No, objects passing messages is fundamentally what OOP is. Alan Kay never envisioned these shitty "design patterns" or cyclically referential mutable state temporally coupled nightmares that are "OOP in practice".

If you want to program like a computer expects and you want abstraction, you do something in between procedural and functional programming. Functional programming is easy to apply to a von Neumann computer, but OOP is not.
>>
>>58666045
So you admit you're 12?
>>
>>58666064
How do you get that from what I said?
>>
If OOP is so good then surely you can come up with a reason other than quoting the theoretical outcome of modular and reusable code (which is never achieved) or the fact that it's widely used in industry (because of incompetent management originally and pure inertia now)?
>>
>>58666063

>objects passing messages is fundamentally what OOP is
That's just a way of implementing it. There are object oriented languages that don't do that at all. Study more, kid.

>OOP is not
Like how not? You don't know what a virtual method table is? You prefer to have stack overflows, I see.
>>
New thread:

>>58666124
>>58666124
>>58666124
>>
>>58666117
>that's just one implementation
wrong, message passing is the concept
calling a method is said to be passing a message, for instance

>virtual method tables
incredibly concrete and specific to particular languages with OOP
>>
>>58666137
There was already a thread going on, you anime freak.

>>58661502
>>58661502
>>58661502
>>
you're all retarded. This is like arguing which is a better car for x situation: an average honda civic or chevy truck with 4 wheel drive. If you're just trying to drive to your gf's house 10 min away, the civic would be a better choice. If you're gonna go drive up the hills to the mountain in the snow, the chevy would be a better choice. Just like if you know your program is going to need a lot of objects, then OOP would be the better choice. All depends on what the program does. You're all faggots. It's so simple to understand but you insist on arguing about it still.
>>
>>58666144
>we already split the thread hours ago
So it's not a proper thread then?

>you anime freak
Oh, so you're new
>>
>>58665808
OOP is a fucking failed meme

Veteran C++ user here. You guys have no clue what you're talking about.
>>
>>58665493
>they aren't using a language with dynamically scoped parameters, giving the best of both worlds of globals and local arguments
>>
is dvorak a meme or is it really superior?
Kind of want to mix it up.
>>
>>58666485
it fucks with your vim keybindings so meme
>>
>>58662275
Nah, R is very nice, actually.
You just have to realize how R works. If you ONLY have a Pajeet-compatible background (You know, those modern OOP languages, like C++, Python, Java, C#, possibly Ruby), and write all code as though that was the only way to do things?

Yeah, no shit R is going to be weird because it isn't one of those languages. If you have a well rounded background and knows some declarative languages (SQL, Prolog), functional ones (Haskell, OCaml, F#), and just plain different ones (Lisps come to mind here), then R is just different. And it's not very hard to understand how it works.

Programming background is a nefarious term. You must have knowledge broader than the Pajeet, so that you may pivot to jobs and roles he cannot bullshit his way into yet, and deeper than the Pajeet, so that you are more important than him, and won't be laid off when he starts costing the company money.
>>
>>58666559
What do I use R for?
>>
>>58666485
>is dvorak just an element of a culture or system of behavior passed from one individual to another by imitation or other non-genetic means, especially imitation or is it really superior?
Really now?
>>
>>58662348
> Proprietary
The FSF says that you're retarded.

> OOP meme
As opposed to C++, Python, JS, C# and Ruby, Java is Object Oriented. Right.

> PublicStaticAbstractDogShitFactories
You can write shit code in any language. But you would never have a static abstract factory you retard. You might have a static factory, like:
LocalDate.of(2000, 12, 23)

But that's... not exactly a bad thing.

You can do the same thing in C#, Python, etc.

>only used because big numbers of lines of code required give management the false impression of productivity and make them feel warm and fuzzy inside

No, there are actual good reasons to choose Java:
> Ease of deployment, just hand the system a jar, or your application server a war, and it's deployed.
> Mature building tools that deal with dependencies
> Lifecycle management with CI, unit tests, integration tests etc. is easy to set up.
> Actually pretty fucking fast, with great JIT optimizations
> Scales well, with mature, best-in-class threading operations
> High quality libraries for everything you'll ever need
> JDBC lets you talk to any rdbms on the planet with zero hassle.
> Mature frameworks that makes things significantly easier for you (jOOQ, Lombok, etc.)

These are actual reasons to use Java for your project.

This retarded meme needs to die.
>>
>>58666808
>The FSF says
stopped reading right there
>>
>>58666898
> The FSF doesn't know about proprietary
neo /g/ everone.
>>
>>58666919
>The FSF knows about anything
neo r/g/ everone.
>>
>>58665947
Yes. Actually doing something real with it. Try some avr shit.
>>
>>58666972
> Being this tsundere
I bet you even wear programming socks.
>>
>>58667178
It's 8am in the fucking morning you psychopath
>>
>>58667273
Actually, the world is round, and it's not 08.30 everywhere.
>>
>>58667374
It is 8:51 right now in the most anime place on earth so that's the only thing that matters
>>
>>58662655
Haha i also use nigger a lot. Upvoted dude
Thread posts: 332
Thread images: 34


[Boards: 3 / a / aco / adv / an / asp / b / bant / biz / c / can / cgl / ck / cm / co / cock / d / diy / e / fa / fap / fit / fitlit / g / gd / gif / h / hc / his / hm / hr / i / ic / int / jp / k / lgbt / lit / m / mlp / mlpol / mo / mtv / mu / n / news / o / out / outsoc / p / po / pol / qa / qst / r / r9k / s / s4s / sci / soc / sp / spa / t / tg / toy / trash / trv / tv / u / v / vg / vint / vip / vp / vr / w / wg / wsg / wsr / x / y] [Search | Top | Home]

I'm aware that Imgur.com will stop allowing adult images since 15th of May. I'm taking actions to backup as much data as possible.
Read more on this topic here - https://archived.moe/talk/thread/1694/


If you need a post removed click on it's [Report] button and follow the instruction.
DMCA Content Takedown via dmca.com
All images are hosted on imgur.com.
If you like this website please support us by donating with Bitcoins at 16mKtbZiwW52BLkibtCr8jUg2KVUMTxVQ5
All trademarks and copyrights on this page are owned by their respective parties.
Images uploaded are the responsibility of the Poster. Comments are owned by the Poster.
This is a 4chan archive - all of the content originated from that site.
This means that RandomArchive shows their content, archived.
If you need information for a Poster - contact them.