r/computing • • Oct 25 '11

Engineers and their programming...

Post image
0 Upvotes

8 comments sorted by

2

u/gufcfan Oct 25 '11

I hate this subreddit. Makes me feel stupid all the time.

I have no fucking idea what that was about.

3

u/a_dead_baby Oct 25 '11

Its funny because the code typed is not legit c++ code. It wouldn't run and yet the person who wrote it was making fun of people who couldn't code.

Thats my take on it anyways.

0

u/obsmike92 Oct 25 '11

Haha, that's the extent of my one semester of Matlab c++ programming. My "professor" was a grad student the year before and was god awful at teaching so I ended up teaching myself and got an A in the course. she ended up getting fired. The kid who wrote the status ended up in my dorm every day asking for help and tutoring. but yeah I wouldnt be surprised if there was errors in my code since I'm pretty rusty in C++ now

2

u/Robial Oct 25 '11

Yea, it's kind of weird how its a mix of Matlab and C++. #include, int main(), and return 0 are all C++ while the for loop and end statement are matlab. I'm currently taking one C++ course and then one Matlab course.

1

u/gufcfan Oct 25 '11

I did programming VERY briefly after finishing high school, realising quickly it wasn't for me.

We were taught some Pascal and introduced to C also and were taught the two alongside each other for quite a while. In my extremely uneducated opinion, I thought that was retarded.

2

u/swimmernick Nov 29 '11

Most places start off with java or python now, both are very much easier for someone new to pick up

2

u/afuckingHELICOPTER Oct 25 '11

I'm not familiar with the language, so maybe it automatically does it, but wouldn't this just go on forever because it never increments i?

2

u/SteveRyherd Oct 25 '11

I believe that's intrinsic to the "for loop" in matlab, you can set a minimum and maximum and the step is defaulted to 1.

for i = min : max

To set the increments to something else, I think you do:

for i = min : step : max