Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

I am writing a game and my friend has offered to help me as it is a RPG and will

ID: 639699 • Letter: I

Question

I am writing a game and my friend has offered to help me as it is a RPG and will take a long time to do the "scripting" bit of the game.

The problem is IMO he's not that good a programmer :( (add flame war here). He has only programmed in Java and VB and keeps saying really stupid things to me like "Why don't you drag and drop an onClick event" to design my UI when I'm using DirectX.

I tried explaining pointers to him but his response was, if it's just a variable that holds a memory address, why don't you just use an int?

I create an instance of an attack class and give the creature a pointer to it so if several creatures use the same attack there is only one instance of it. He keeps saying why not put if statements in the creature class for every attack class and set true for the ones that are there.

He has programmed mainly in VB and a little in Java just to learn OOP. How can I explain advanced C++ concepts like pointers and memory management to him? He just doesn't understand there are no super functions like form.show in C++.

Explanation / Answer

I think the way you explain this to a Java or VB.NET programmer (who has only used those languages) is to... not explain it to that programmer. Explain it as you would explain it to any regular person. Pointers are more powerful than any construct expressible in Java or VB.NET. Therefore, any attempt to understand pointers in terms of features available in the other languages is not going to be possible. Whatever abstraction someone might draw on top of those languages to express pointers will invariably fall apart when it comes time to do anything like pointer arithmetic.

If your programmer wants or needs to learn how pointers and C or C++ work, they have to learn the language(s). And they need to learn those languages as what they are, not as "Java/VB.NET, with a few of the semantics changed" -- because there's little code worse than Java written in C++. They can go on and on about how Java is part of the C family of languages, and therefore things should translate from one to the other simply. Unfortunately, that's not always the case. Spanish and French are part of the same family of languages too, but it's unreasonable to ask someone who knows only Spanish to comprehend a text written in French. The difference between these languages is a similar gulf. (A larger jump would be something like to a functional language (e.g. Haskell), which would be more like jumping from Spanish to Russian)

If he is unwilling or unable to understand pointers, then he's probably not all that good a Java or VB.NET programmer either, and maybe it's time for him or her to stop contributing to your project.

Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote