Would anybody be interested in tutorials or explanations that I could give for various programming things. I have a few in mind that would be good for people to learn. Nothing they couldn't learn from books, but I've noticed that a lot of the books are written at a college level, and without programming for a while(long enough to think like a programmer) it can be hard to understand or grasp.
I don't claim to be the best programmer or anything, but I've learned a thing or two messing around with it. The tutorials would all be in C#.net, I started in VB.net, moved on to C# and forgot just about everything from VB.
Some things off the top of my head I could cover:
Basic explanation of classes
Extending classes
I would also be happy to take suggestions, because sometimes it's hard to think of things that would be helpful off the top of your head, so I would do my best to work on suggested tutorials too. I'm somewhat busy with football and school, but I'm sure I could find time to do this because I enjoy programming and I find you get a better understanding when you explain things to others. So if enough people would be interested in this I might try to do this.
Tutorials ect
explaining some things about classes would be cool. as far as i know (using c++ here) it seems like it's just making your own data type (although a bit more complex). i've got a book myself, but it would be neat to see what your experience with classes is.
ASPARTAME: in your diet soda and artificial sweeteners. also, it's obviously completely safe. it's not like it will cause tumors or anything. >.>
always remember: guilty until proven innocent
always remember: guilty until proven innocent
It's a shame C# doesn't have templates because that's something that's usually worth a tutorial. But classes and inheritance would be a good idea. Show them how to make a base class, then a new class that inherits members and functions from the parent class. Don't forget to cover constructors, destructors and statics.
You have it right, but yes you oversimplified it. It's creating your own data type, with functions that perform operations on it's values, and a lot of other things too obviously.[cc]z@nd! wrote:explaining some things about classes would be cool. as far as i know (using c++ here) it seems like it's just making your own data type (although a bit more complex). i've got a book myself, but it would be neat to see what your experience with classes is.
When you say template are you talking about a language feature? I think I've heard of them in C++ but I know nothing of them. If you mean like an example project that you can start new a project off of in you IDE then it does have them.Altimit01 wrote:It's a shame C# doesn't have templates because that's something that's usually worth a tutorial. But classes and inheritance would be a good idea. Show them how to make a base class, then a new class that inherits members and functions from the parent class. Don't forget to cover constructors, destructors and statics.
I was planning on extending and inheritance with extending a control such as a textbox, but I could do it with a base class also.
I might explain polymorphism too with interfaces, abstract classes, and overriding methods too.
Templates are a C++ preprocessor feature that let's you define classes and functions without having to specify certain variable types in the definition. Instead you have a place holder that works similar to the typedef macro. When you declare an instance or invoke one of these templated functions, you specify in angle brackets the data type that will be used. When the code is compiled, the compiler creates in assembly a version of your function or class for each data type that uses it in the rest of your code. Much easier than having to create several versions of the same class that use different data types.
I generally use inheritance for custom data classes, but I guess in the .net environment it becomes useful to inherit from controls as well.
I generally use inheritance for custom data classes, but I guess in the .net environment it becomes useful to inherit from controls as well.
This sounds kind of similar to generics, could be much different, I didn't understand exactly what you said, but would it be like having a List<T> class where T can be any type, and each method works for any type?Altimit01 wrote:Templates are a C++ preprocessor feature that let's you define classes and functions without having to specify certain variable types in the definition. Instead you have a place holder that works similar to the typedef macro. When you declare an instance or invoke one of these templated functions, you specify in angle brackets the data type that will be used. When the code is compiled, the compiler creates in assembly a version of your function or class for each data type that uses it in the rest of your code. Much easier than having to create several versions of the same class that use different data types.
I generally use inheritance for custom data classes, but I guess in the .net environment it becomes useful to inherit from controls as well.
It's a lot like generics, but doesn't require the .net environment. I'm not sure how C# handles the type used but C++ is explicit in the types for templates meaning you can't use autoconversions. As usual the C# implementation of things is more "type safe" as they like to say. But may as well go over generics for people.