Please settle my and my wife's argument (got yelled at because of it)

The argument, she yelled at me because i'm wrong and i'm talking crap so let's ask others here the same question (I won't bias it by saying what I agree with or what She agrees with to keep the argument fair and valid) anyway she's been on a computer science course and has a degree went uni etc etc, i'm just a self taught programmer without a degree, that said, I've managed to write stuff over the years people with degrees have been quite envious of by the comments they've made to the line of (how the hell did you manage that? in a good way :P) lol

So anyway the Argument.......

One of us claims..... Learning Object Orientated Programming first..... leads to the problem, OMG what is this Procedural language thing? and basically find it /HARDER/ to learn say something like C after only knowning and only ever programming in an OO like Java, C or Pascal would be Alien to them and find it much more difficult (because they only know about classes and they would not be able to cope with procedural language) - the other one of us disagrees, and says no. It will be easier to learn C after coming from Object Orientated world because once you quickly pickup on the fact your code stays the SAME what in reality changes is a lot of overhead, eg something.somethingelse.please.just.letmecallthefunction.ineeed.client.print("Hi"); - it now becomes print("Hi"); based on that, forgetting crap is a whole lot easier than learning huge overheads eg from C to Java vs Java to C...

So who's more valid? - try googling that, it's not as easy as you think to find out the answer to this question.

Either way, you're going to have to say (like you really mean it), "I'm sorry, honey. It was all my fault.

Perhaps you two need a hug?

I don't quite understand the question. Perhaps you can both calm down and rephrase it?

If you've learnt object-oriented programming you've already learnt a language such as C++, right?

Anyway, I'm not sure there is a "best" way. If you start off with procedural languages like C, you will have to adjust to object-oriented. If you start off with object-oriented you may have trouble with things like processor datasheets which are pretty dry reading.

Yes.... either way you will have learning curves agreed.

but (which is easier to do).... OO to Procedural? or Procedural to OO.

(Learning less, eg java to c, has to be easier than C to Java)??

lol no, i disagree with her my opinion is just as valid as hers, I was just wondering what the consensus was here, easier to learn Java first then learn C? or Learn C first then learn Java....

I know neither c or java, and I tried to learn both straight off about 2 years ago as a junior in hs, I basically didn't get very far with either but c seemed easier to learn, and know after learning about the arduino the past almost year its been much easier for me to learn c, seems more logical to me, I look at c code and it doesn't look hard to follow, I look at java and it blows my mind as of now lol
Doesn't answer much but maybe it'll help :slight_smile:

Different people learn in different ways. There is no real "right" way or "right" language to learn first. Probably what works for you is right.

Nick i admire your diplomacy skills.... :stuck_out_tongue:

As Nick Gammon says, I've seen it work both ways in different ppl.... when I first learnt programming in school, they still had those 2 5.25 inch floppy machines around...proceedural....but some of my youngest cousins these days start off happily in more modern languages with oop...and the fact remains that python which is really a hybrid in terms of how it is used is one of the simplest languages to learn.... but either way in this specific case you're probably better off taking a chill pill and following Runaway Pancake's advice :slight_smile:

Nick is right. cjdelphi, you and your wife are both wrong1. Programming is primarily a mental exercise. Each human brain is unique. What works for one person will be a disaster for another. And vice versa.

1 Wrong in the sense that neither you nor your wife can possibly project what works for you onto another person or a group of people. What you are trying to do is no different than projecting how you feel about a car accident onto another person. You may feel angry. Your wife may feel sad. Which of you is wrong?

P.S. Was functional programming not considered in the argument? What about declarative programming? Why were only procedural and object-oriented discussed?

I'm with Coding Badly. By way of illustration, let's step back from C/C++ and consider

If you choose an answer to this question at random, what is the chance you will be correct?
A) 25%
B) 50%
C) 60%
D) 25%

Most people struggle with the answer, and never realize that it's the question that's flawed.

Your question contains within it two (logically fatal) flaws: "Easy" and "Wrong" :grin:

Programming languages are tools and, like other tools, need to be suited to the task at hand (after all, one would not drive screws with a hammer - or nails with a screwdriver).

(I'm thinking this topic should be moved over to Bar Discussions)

I'm with Coding Badly

Me too.

However most of the best engineeres have some sort of language difficulty and I think that suites procedural languages better than OO languages.

I also agree with Coding Badly. Good programmers, in my experience, have their brains wired slightly differently to those that can't do it, but it's not a consistent difference. Some will find more success with one route, and others with the other route.

I just think new prospective programmers are lucky to have so many choices these days. When I started, there were no OO languages. Having said that, it was also before VB, so it wasn't all bad.

I'm not quite sure there is a question. The difference between procedural and object oriented is (in my perspective) about the wrapping and organization. Object Oriented makes it easy, simple and intuitive to make modular and better organized code. C however takes a bit more discipline.

If you look inside a method or a function that does the same, the code will be very similar, so in reality for you to program in C++ you have some knowledge of C or procedural language. She should admit that by the way.

So my personal opinion is that it may be more difficult to move from object oriented to procedural because there is more work to it. The real problem, like others have pointed out, is that this is something you normally don't choose and you can only do it once, so whatever opinion one might have will always be a reflection of their own experience. You either go from procedural to object oriented or vice versa. You won't do both.

So the best course of action is to stop having this discussion and focus on more interesting things. :stuck_out_tongue:

cjdelphi:
It will be easier to learn C after coming from Object Orientated world because once you quickly pickup on the fact your code stays the SAME what in reality changes is a lot of overhead, eg something.somethingelse.please.just.letmecallthefunction.ineeed.client.print("Hi"); - it now becomes print("Hi"); based on that, forgetting crap is a whole lot easier than learning huge overheads eg from C to Java vs Java to C...

What if you have two serial ports and an lcd? you'd write lcd_print(), serial1_print() and serial2_print()...

Learning C after Java must be hell... at least for me it would.

(deleted)

If a man says something in the forest and no woman hears him ...

is he still wrong?

2 diferent people with diferent skills,well your bound to both disagree so agree that you disagree and both can get on with what there good at in order to keep the harmony. it would be like a englishman married to a german woman you would always get differences. be thankfull that you both are highly skilled people in the first place!

if you must know, i agree on the fact going from something that's object orientated like java to C is easier than going from C to java... mainly because it's simpler and easier to learn .