C++ vs C# - What Programmers Need to Know About Their Similarities and Differences

  Рет қаралды 148,983

Coding With Chuck

Coding With Chuck

Күн бұрын

Programmers, software engineers, project managers, and developers often ask for recommendations for what programming language and development platform to use. In this video,
Chuck explains the overall differences between C++ and C#. C# and C++ are similar in many ways (C# design was based on C++), but there are striking differences. Whether you are needing to choose for an upcoming project, or trying to decide which to learn first, check out this video!
For more, see the full article at Udemy - blog.udemy.com/c-sharp-vs-c-p...
Check out the other videos on this channel for more details and check out our training courses at www.McCulloughAssociates.com.
You can find our Udemy courses here:
www.udemy.com/user/chuck-mccu...
0:00 Introduction
0:24 File Organization
1:21 Basics
2:38 Execution Environment
3:39 Type Specifiers
4:50 Memory Management
6:00 Generic Programming
7:05 Functional Programming
7:50 Inheritance
9:30 Standard Library

Пікірлер: 324
@rohansampat1995
@rohansampat1995 2 жыл бұрын
Wow this really goes over stuff really well. I want to point out the C# does actaully have a tiny amount of control over the GC as you can finalize things. Now this does not guarentee like... anything but you can finalize something and clean up resources in a "destructor" in C#. C# also supports pointers and memory management through unsafe code but no one should really be using it unless they are a niche exception.
@KayFiiya
@KayFiiya 2 жыл бұрын
thank you daddy, i miss you
@gondoravalon7540
@gondoravalon7540 2 жыл бұрын
@Jan What do you mean?
@McCulloughAssociates
@McCulloughAssociates 2 жыл бұрын
I love the passion everyone has for their favorite language! Just as a bit of background, My first C++ project was in 1985 using CFront and my last was completed just a few weeks ago - a rather large application for the US military. C&C++ are my first loves as those were my first languages. I have built dozens of projects over the decades in C++, C#, and Java and I find all three to be quite capable and useful and enjoy all. I also have comprehensive training courses on all three platforms with thousands of students. Point is, I know and use all 3 and really have no preference. We left 30 minutes of video on the cutting room floor when making this, so we didn't cover every detail in this short video. Our goal wasn't to declare a winner, but to provide an answer to a very common question.
@ryanrivera9623
@ryanrivera9623 2 жыл бұрын
I love how Java and C# are so similar. I learned to program in Java, and was able to pickup C# very quickly, and love working with both. I’ve only dabbled in C++ in my side Arduino/Raspberry Pi projects, but hope to become proficient using it in my spare time. Thanks for the great information!
@nguyenucminh4966
@nguyenucminh4966 Жыл бұрын
@@ryanrivera9623 I'm no expert but the reason why you could pick it up so fast was because of the same concept of the two languages: they both run on a virtual machine, one is JVM while another is CLR.
@gooniesfan7911
@gooniesfan7911 Жыл бұрын
Hey what was your project for the US military
@redrevyol
@redrevyol 3 ай бұрын
I've been a C# programmer for a few years, but I am switching to C++ because C++ can be portable and can be interfaced with other languages. Microsoft just can't provide tools that I want.
@erik9817
@erik9817 Ай бұрын
Thanks for the perspective. I have been struggling in deciding between C# for applications/backend and C++ for graphics rendering, maybe I will be fine with using both. But I feel I need to make a decision in order to facilitate efficient learning. I'm not a beginner but feel my progress is slowed by my tendency to jump between the two. Not sure if it is healthy.
@AlDunbar
@AlDunbar 2 жыл бұрын
As an amateur musician, I hear C sharp and think: "isn't that the same as D flat?"
@NTTCode
@NTTCode Жыл бұрын
C# is the most beautiful language for me so that after 5 years of using it, I have no intent to switch to other languages.
@KaustavMajumder
@KaustavMajumder 3 ай бұрын
Can you help me with one thing? A desktop application that I wrote in C sharp would work on my system. But would not work on many other computers using the same OS. How does one deploy a C Sharp application?
@dougwarner59
@dougwarner59 2 жыл бұрын
personally, I though learning the programming rules for C++ was a easier than C#. But once I learned each language I found C# was a lot to use because of the reasons you mentioned.
@JVApen
@JVApen 2 жыл бұрын
As C++ programmer, I really like that it's represented in a correct way. That's really rare.
@BasPower12
@BasPower12 6 ай бұрын
Yes, I agree as a C++ devoted learner it is often misunderstood and underrated and newer languages like Rust are being overrated.
@zacharychristy8928
@zacharychristy8928 2 жыл бұрын
To your point about C++ being useful for games, that's mostly true! If you're building an engine, or making a game from scratch C++'s performance is practically essential. I've used C# far more often for games though, since it's supported by engines like Unity and Godot, and tools like LINQ and interfaces can help manage complex collections of objects and their interactions. I like my engines in C++, and my game code in C#.
@Erlisch1337
@Erlisch1337 2 жыл бұрын
Depends on what kind of game/engine. If its its advanced/high performance 3D then yes I would go with C++. But if its just a 2D or basic 3D I would go with C# for the ease of use.
@LyricsQuest
@LyricsQuest Жыл бұрын
Good point. C++ Game Engines can be multiplatform since they use multiplatform gui code, while the c# doesn't provide the GUI code so it can be used everywhere including linux (.NET GUI does not work properly in Linux, even with WINE... only if you're lucky). Portability and ease of use, that's a great combination.
@justadude8716
@justadude8716 10 ай бұрын
Recently Godot finally made C# and their own language feature identical, making C# ever better choice for 2d games.
@adam7802
@adam7802 Жыл бұрын
Currently my tech stack is only web based things but I've really wanted to dig deep into other languages and working with the hardware more directly, been trying to learn C using GBDK (a library for writing gameboy games) which has been a huge be very fun learning curve! I've also been interested in learning C# just for job opportunities really, since I think I can probably pick that up faster and it seems to more there is a variety of work you can do with it. Even though I'm not looking at C++, I'm going down a bit of a rabbit hole of information here and absolutely loving it, really enjoyed the video.
@weskerend507
@weskerend507 Жыл бұрын
What an amazing video, straight to the point and very informative, thank you!
@manuprakash8456
@manuprakash8456 Жыл бұрын
I liked this video and agree to most of the facts stated. This was what I was looking for. I would like to add a few things about c++. C++ covers really wide range of hardware--ranging from 8-bit microcontoller to 64-bit intel architecture. I would recommend undergrads to go though c++ concepts atleast once to understand how C++ rides the horse (hardware.) Once you are through C++ you would intutively understand how C# is working. I, myself, started from assembly language then C & C++ to-and-fro then c#. All because of the type of applications that I was developing.
@gasparmc
@gasparmc 4 ай бұрын
Thanks, sir for this robust overview
@denielalain5701
@denielalain5701 2 жыл бұрын
Hi! 6:01 - In seashark there is no way to alter garbage collection indeed, however ~destructors are worth mentioning.
@rp8133
@rp8133 2 жыл бұрын
I'm late in here. Thanks for this comparison. As a software developer working more than 2 decades with C++ and C# I can agree with your speech. Both languages are similar but do have subtle differences. As a guide I would suggest the following: For UI use C# and technologies that are best for the task. For near-hardware-work use C++. To close the gap between C# and C++ use C++/CLI. For implementing communication protocols use what ever you want - there are so many available...
@dharanibala8443
@dharanibala8443 Жыл бұрын
Which language helps to understand computer better?
@DefaultGuy84
@DefaultGuy84 7 ай бұрын
​@@dharanibala8443C
@michalsvihla1403
@michalsvihla1403 5 ай бұрын
@@dharanibala8443 When it comes to abstraction starting from most abstract: C# > C++ > C > Assembler > Binary
@BrandyBalloon
@BrandyBalloon 3 ай бұрын
@@dharanibala8443 C
@jhonyortiz5
@jhonyortiz5 6 ай бұрын
This was very comprehensive, thank you.
@the_bogeyman.
@the_bogeyman. Жыл бұрын
I will start a basic programming course next year and I need to choose either C++ or C# (and get the specific text book that goes with it), but I am still confused on which one to chose. I have no previous code experience, and my long term plans are try to get into IT and network positions where I work. Python is also something I should try start to learn too and maybe dig into Cisco stuff (but their courses other than expensive are not beginner friendly either). I understeand that the stuff to know in IT is infinite...but I gotta start somewhere. I've already done courses "similar"ish to the US Comptia A+ but I wish I started earlier 20 years ago. Thnx for any advice.
@RandomDude00001
@RandomDude00001 9 ай бұрын
I learned C# first since it was the language Unity using which I use for making my games.
@balloney2175
@balloney2175 2 ай бұрын
Very well explanation and differentiation.
@McCulloughAssociates
@McCulloughAssociates 2 ай бұрын
Glad you liked it!
@NZRanger
@NZRanger 2 жыл бұрын
When working out what tools to use, use the tools that are right for the job! If you want RAD on a PC platform then don't shy away from learning Pascal and use Lazarus/Delphi which allows RAD for everything from Windows to Raspberry Pi. I've been coding for over 30 years and have certifications in languages like C++/C#/Java but I'll use the best tool for the task at hand. It's sad that such great languages like Pascal/Delphi fell off the radar due in general to pi$$ing competitions.
@uni-byte
@uni-byte 2 жыл бұрын
Any job these days is going to require C#, Java Script and Python. C++, while a superior language for sheer performance (in the right hands), does not lend itself well to the "average" code monkey. It's too easy for them to hang themselves with it. For that reason, it you have the honest ability to properly deal with C++ (and C) they are certainly nice to have on your resume and will probably allow to work your way into a higher paying job.
@Hcloud65
@Hcloud65 2 жыл бұрын
I took C++ and VB in school and taught myself C#, I found that C# was easier to learn; its like C++ and VB had a baby. You get the power of C++ and the Graphical interface like VB all in one. I have been programming in C# for about 12 years now from game programming to databases and other apps at work.
@amitzohar3107
@amitzohar3107 2 жыл бұрын
very good comparison. regarding the line "Programmer has no control over GC", while that's mostly true, the programmer can force the garbage collector to run by calling GC.Collect().
@McCulloughAssociates
@McCulloughAssociates 2 жыл бұрын
True and .net provides better control than Java. I wouldn’t recommend explicit gc except in very unusual circumstances.
@amitzohar3107
@amitzohar3107 2 жыл бұрын
​ @McCullough & Associates yea it's not recommended but it's still used in cases where the programmer did some action that caused a lot of memory to be unused and unreachable and he wants the GC to free those memory allocations from the RAM at that point, so he calls GC.Collect() and after those memory allocations are freed the app will consume less memory and run faster since the GC, which freezes all threads (except for Gen2 collection when Background GC is performed) to check all memory allocations and free unreachable ones, will have much less memory allocations to review, thus the app's threads will be frozen for a shorter time, thus the app will run faster.
@Cara.314
@Cara.314 2 жыл бұрын
the best control you have over GC is structuring things to not need it very much. dont do mindless allocations of stuff, make good use of value types, so on, so forth. There's all sorts of stuff in c# that enables you to work around the GC, just look into the fixed keyword as 1 example.
@marna_li
@marna_li 2 жыл бұрын
Record types are data classes generated by the compiler that are immutable. By default, they are classes and passed by reference. There is also a struct equivalent in "record struct". Yes, they are great for defining data transfer objects. Thanks to their syntax with primary constructors.
@McCulloughAssociates
@McCulloughAssociates 2 жыл бұрын
kzbin.info/www/bejne/hovTfKlurMt8kJY
@OperationDarkside
@OperationDarkside 2 жыл бұрын
I startet with C# because of my employer, but soon got hooked on the performance C++ offered. Some C# frameworks were terribly slow back then. Especially .NET Entity Framework. Almost all private projects are C++ now except where I'm forced to use other languages. The only thing I really miss are human readable compiler errors. Especially template-related error messages can be almost unreadable.
@swapode
@swapode 2 жыл бұрын
You might really enjoy Rust.
@michalsvihla1403
@michalsvihla1403 5 ай бұрын
What compiler do you use?
@hstrinzel
@hstrinzel Жыл бұрын
Seems to me that C# is VERY similar to Visual FoxPRO, the language I know and love: An Object-Oriented language that is compiled into some intermediate code that kind-of interpreted with a Runtime Library. Easy to learn, very rich language designed to create interactive user-interface things in Windows and the Web and with the addition of the Record type they are getting closer to the data-centric model in Visual FoxPRO. With West Wind Web Connection for FoxPRO developing Internet Databases is a dream, and I can certainly see that I am NO missing much with C++ and C.
@MrAbrazildo
@MrAbrazildo 2 жыл бұрын
7:50, it's good to mention that lambda in C++ is just a f() inside another. It can be used as a "functor", as well as just a scope, to be used 1 or more times, granting that all variables created there will disappear once lambda returns. Overall, to active a f() you just need its address, which can be provided by the name of the f(), a pointer to it and a provided bind by STL. Hence, the name of a f() can be used as a functor too. Unfortunately, you can't force a integer value to be interpreted as a f() address, and vice-versa. 7:58, and multiple derived too. 9:25, it has an explicit syntax for interface. 1 can see some member-f() be declared as: virtual fname (its parameters) = 0; Meaning that linker should not report an error if it can't see the f() definition.
@McCulloughAssociates
@McCulloughAssociates 2 жыл бұрын
Thanks for your comments. We could have spent an hour digging into the details!
@L1ghtOn3
@L1ghtOn3 2 жыл бұрын
Really love C# after doing some android in Java then done games on Unity fell in love with C# as it just felt so similar but an easier C++. I use C++/Blueprints on UE4/5 but still prefer C# even though for FPS and realism especially UE5 is the way to go until Unity catches up, don't know why but the remote 5 not working for testing with the new starter assets and UI has hit some indie devs hard in the pocket the last few years since 2019.3. I was an avid Unity supporter until recent but I'm switching to UE5 full time now as Unity has let me and many others down chasing high end graphics and other unnecessary non indie developments. I will miss C# but still might use it for .net web/UWP/MAUI etc in future and if Unity gets the finger out and gets everything working again in support of indie devs I might have another look in a few years but never thought I'd leave Unity but they forced my hand waiting over 2 years just to do simple testing in real time, just not good enough for large 3D android games that take an hr to build just to test. Nope, so looking forward continuing my C++/Blueprints journey 👍
@simonfarre4907
@simonfarre4907 2 жыл бұрын
If you learn C++, learning C# will be a walk in the park. That is why I *always* tell people who have a talent for programming or a passion, go for it. Learn C and C++. Literally every single language after it, you will pick up in a week or two.
@kuchukboromdebbarma2117
@kuchukboromdebbarma2117 2 жыл бұрын
Not really Language like elixir requires its own set of mindset
@simonfarre4907
@simonfarre4907 2 жыл бұрын
@@kuchukboromdebbarma2117 functional programming languages does require some added study, but I would argue that has less to do with programming work in practice and more to do with the theoretical. Functional programming places an artificial constraint on what you can do (or should do) and doesn't map particularly well to how computers actually work.
@nontraditionaltech2073
@nontraditionaltech2073 2 жыл бұрын
The hardest part of learning C# (as a former C developer myself) is learning all the damn libraries needed for my day job
@andresvallelisboa5511
@andresvallelisboa5511 2 жыл бұрын
@@nontraditionaltech2073 You have google and microsoft docs for that.
@nontraditionaltech2073
@nontraditionaltech2073 2 жыл бұрын
@@andresvallelisboa5511 all day, every day lol
@mahkhi7154
@mahkhi7154 2 жыл бұрын
The question isn't Which to Learn, but Rather which to Learn First. Learn 1, you can Learn the Other in 30 days. I've never Learnt PHP, however since I know C/C++ and C#, I can easily understand PHP. The question, which First? C#. C# is like Visual Basic. It is forgiving if you make mistakes. After C#, you can learn C/C++. You'll have to learn a little extra to see how it works at a lower level, closer to the hardware.
@annekedebruyn7797
@annekedebruyn7797 2 жыл бұрын
I learned Visualbasic back in highschool. Never used it. So going with C# was a good place to start for me. It doesn't have to be identical. But if certain things crossover it makes the much less frustrating. While I haven't touched C(++) I can see how that would be the same for that language and C#.
@sbypasser819
@sbypasser819 2 жыл бұрын
what if im in highschool , i cant learn a language in 30days. So i learn c++ because it runs on android and c# doesnt. And i want to program for android.
@annekedebruyn7797
@annekedebruyn7797 2 жыл бұрын
@@sbypasser819 c# can be used for android and IOS apps even. Might not do what you want to do. But C# is multi platform. Check out Xamarin for Android specifically. But ultimately you want to learn C++ anyway so I'd say, if you are willing to start with that and you are still in high school. Please stay with C++. Especially if you want to do computer science at university later on.
@CallousCoder
@CallousCoder 2 жыл бұрын
True and the answer is assembly. I still build upon those 6502 days. And I still can relate performance issues back because of that understanding of assembly - although with x64 it’s not as trivial with that terrible extensive opcodes set.
@Kenbomp
@Kenbomp 2 жыл бұрын
You can learn syntax of c# in 30 days but it will take years to learn the vast library it has. C++ your more on your own. Good or bad
@kirillsviderski4739
@kirillsviderski4739 2 жыл бұрын
Sent this to my students! Subscribed)
@McCulloughAssociates
@McCulloughAssociates 2 жыл бұрын
Thanks!
@IamusTheFox
@IamusTheFox 2 жыл бұрын
Extremely well done. From my admittedly short experience with C#, I find it gives you a ton of tools to do everything. C++ gives you the machinery to make the tools. Sure C++ doesn't have a webapi out of the box, but you can make more meaningful abstractions with C++ than C#. That, and C# is a OO language first and C++ is exactly as OO as it is functional.
@desarrollou71x72
@desarrollou71x72 2 жыл бұрын
I started with Basic from my old Atari 800XL.. then moved to Python... then C# and now C++... iḿ pretty sure will not move anymore.. i use Unreal Engine, Qt Framework, SFML and really happy with C++.....
@Larry821
@Larry821 2 жыл бұрын
This was interesting. But I think which language to learn depends more on 1) the OS environment you are tasked with developing apps for, 2) why you are learning the language, and 3) what you hope to do with it. In the Linux world you are traditionally developing in C/C++ (or a higher level language) not C#, though that is at least possible now. In the Windows world, at least in the case of apps, C++ is rarely used anymore and the scale tips mightily to C#. Professional programmers will tend to want to learn those languages they enjoy and bring them the best market opportunities. Companies will tend to develop in the languages which make their IT staff most productive. On both these counts I think C# is vastly superior, at least in the Windows world, which, after all is the environment it was created for.
@justadude8716
@justadude8716 10 ай бұрын
For developing and shipping a product c# is the clear winner unless your application dictates you use c++
@KhaosEmeraldx
@KhaosEmeraldx Жыл бұрын
I really need to wrap my head around C++ better. I’m a game dev with experience in C# and whilst I love it I really feel like there is an upper limit to the efficiency so I am trying to learn the other side. Pointers and garbage collection are the two bits I get really lost on!
@user-nz4og2tj2i
@user-nz4og2tj2i 10 күн бұрын
I wrote a custom memory pool system in C# that uses unmanaged memory. Leading to me using only structs, field offsets and fix pinned buffers for every game... C++ is still faster even using virtual/abstract classes. You will not regret it.
@journeylife7491
@journeylife7491 2 жыл бұрын
Gosh.....I am so discouraged, but won't give up trying to learn one of those languages. I am sure this was helpful for someone that have more than a basic idea of coding. Maybe one day I will understand this video in two years. :)
@McCulloughAssociates
@McCulloughAssociates 2 жыл бұрын
kzbin.info/aero/PLXd94bZTzZ-QaMgLp41ZUb_w0sjLBGjUp
@tek1645
@tek1645 2 жыл бұрын
I started with C++ during high school 😂 Then I did C# for fun and enjoyed it more
@Stabruder
@Stabruder 2 жыл бұрын
Me too
@lewcreative
@lewcreative Жыл бұрын
Sadly I failed my C++ class. I don't really recommend C/C++ as a first language. I recommend a higher level language then going on to lower level languages. I am now doing well in C and C++. I don't love them like Python or Go or Kotlin, But, the knowledge you get from learning this lower level languages is just addictive and makes you love and appreciate computers on a deeper level.
@brownrhythms
@brownrhythms 3 ай бұрын
I spent sometime converting a C++ CLI service over to C#. In terms of syntax, I'll take C# over C++ CLI every time.
@FueRent
@FueRent 2 жыл бұрын
you have quite a good control over GC, it just makes no sense, and afair doesn't work in debug where you would typically want to play with it.
@fnamelname9077
@fnamelname9077 2 жыл бұрын
This is a really great video. I'm happy to report, however, in 2022, inline-declarations are starting to make header-only libraries popular. A lot of projects don't have or need separate implementation files (except, perhaps, for a single one), because of emerging initialization guarantees.
@thingyee1118
@thingyee1118 2 жыл бұрын
Detailed comparison
@mr.shredder5430
@mr.shredder5430 6 ай бұрын
make a video about your favorite c++ framework
@yerd1511
@yerd1511 2 жыл бұрын
both are great
@miansherry6453
@miansherry6453 2 жыл бұрын
Good thumbnail, good explanation.....
@TheBuilder
@TheBuilder 2 жыл бұрын
do one comparing C# and F#
@marna_li
@marna_li 2 жыл бұрын
About generics. In C++, templates are macros run by the preprocessor before compiling code - it generates code for each occurrence. In C#, generics is a feature of the runtime with runtime representation. On the other hand, Java uses type erasure, which is more like in C++. So no runtime info about generic types. A generic type (class or struct) is either open (has placeholders - List, cannot be instantiated) or closed (has parameters set - List or List). In the case of parameters being reference types, it just have to generate one runtime representation of a closed type at runtime and reuse if for all reference types - since it handles parameters that are references with a fixed address of the same size for every type. When it comes to value types you pass the "value" as a parameter, different sizes depending on struct, and thus the runtime generates a new generic type for every variant.
@tomahawk5357
@tomahawk5357 2 жыл бұрын
In C# generics are resolved at compile time, not at runtime.
@au._.79
@au._.79 2 жыл бұрын
C++ templates are not macros and not run by preprocessor neither, but they act like "macro" but it has sense of language grammars rather than just text replacement.
@marna_li
@marna_li 2 жыл бұрын
@@tomahawk5357 Generic type definitions are part of the metadata - as a ”template. Of course, the compiler is aware of the types. But the actual instantiation of a ”closed” generic class or method is at runtime with it in memory. As I tried to say before, the runtime, and subsequently the JIT compiler, creates versions optimized based on the type arguments.
@tomahawk5357
@tomahawk5357 2 жыл бұрын
@@marna_li Generics are resolved at compile time in C#. There is nothing in particular when instantiating a object from a generic class as everything is created at compile time and not at runtime. Once again, generic types are resolved at compile time not at runtime. Speaking about metadata is another subject....
@alphaanar2651
@alphaanar2651 2 жыл бұрын
Mate, you are wrong, in C# generics pretty much work the same way as C++, compiler generates code for each occurrence, as you said for C++. So it is really not a runtime thing
@michaelshollaj6428
@michaelshollaj6428 2 жыл бұрын
I've been programming in C# for long time, so I choose C#, both are amazing, but for my opinion C# is the best!!!
@FromBeaverton
@FromBeaverton 2 жыл бұрын
Good explanation, except horrible mess with templates vs. generics. In C++ templates invariant is generated during compiling time. If it is missing, code would not link. You cannot run library with template class against some new type, because at runtime it is already too late. C#, on the other hand, also generates invariant, but at runtime. As a result, you can instantiate and execute generic class against a new type. If would be nice if this video would mention this huge difference.
@MrAbrazildo
@MrAbrazildo 2 жыл бұрын
4:20, C++ hasn't the interface keyword, but has virtual, override, final and '= 0' for the 1st f() in an "interface". It has also the slowness that only an interface can provide. For strongly typed as parameters and returning, it's pretty easy to code them by yourself. 5:50, oh, my! You didn't mention the containers C++ has in its standard library, all of them managing automatically their own memory, making memory leakings a challenge. And for raw pointers, there's always the option to wrap them into a class, making your own smartpointer, if this last 1 was not an option itself.
@raymundhofmann7661
@raymundhofmann7661 2 жыл бұрын
He looked like a Microsoft c# garbage (collected) language shill to me anyway. Managed languages are for soydevs giving us the climate doom by bloating up memory use and draining all batteries with excessive CPU load.
@user-ir2fu4cx6p
@user-ir2fu4cx6p 2 жыл бұрын
@@raymundhofmann7661 Lol that was my exact thought on C#, fun fact that many famous desktop/Windows application were written in C++, as IT and intensive Windows user over 22 years I can tell from first look at the program, if it's running solid C++ or crappy C# .
@krish3d385
@krish3d385 2 жыл бұрын
I started learning c++ cause i had to, i loved its power, its inspiring i had the full control and understanding. But the job can be done way more easier in java or c# and they were too easy. Eventually i liked the coding part in every language. Its fun.
@fireteamomega2343
@fireteamomega2343 Жыл бұрын
It seems with the meta data and the compilation of c# it would be a security issue as it would be possible to reverse engineer the source code from a compiled state ? I know using c++ there have been times when that might be convenient especially with devices running a program and you may either have lost or simply don't have access to the original code. But I would imagine in a proprietary business model you probably wouldn't want that.
@McCulloughAssociates
@McCulloughAssociates Жыл бұрын
Any program can be "de-compiled" regardless of the source language. Apps containing intellectual property or other secrets is at risk if it is accessible. It requires a more capable skillset to do that with C++ as it is more non-deterministic due to optimization and lack of symbols. But make no mistake, a hacker with your binaries can and will reverse engineer it regardless of the source language. C# decompiles readily into similar source code, however C# is optimized somewhat at compile time. Java, on the other hand, is optimized only at runtime, making decompilation much more deterministic. At best maybe some security through obscurity (which ultimately means no security). Games in the pre-internet era, written in assembly or C utilized an intentional manufacturing defect on the source CD as a sort of anti-piracy. The code often times tried to obscure the check by dynamically overwriting the code in memory then executing it to verify the disk error. A skilled developer could find the instruction and bypass the check in just a matter of minutes.
@kamertonaudiophileplayer847
@kamertonaudiophileplayer847 2 жыл бұрын
I would compare C# and Java. Why? You pointed that, C# as Java using JIT compiler.
@QuikRay
@QuikRay 4 ай бұрын
Both compilers/interpreters were written and are maintained by Microsoft. C# and C++ were written for different purposes, but each can be used to accomplish a given task. Why then did MS come up with a new language called C#??? What was the motivation behind that endeavor??? Can you answer that, objectively????
@McCulloughAssociates
@McCulloughAssociates 4 ай бұрын
MS didn't invent C++. I was a product of Bell Labs (AT&T) and Bjarne Stroustrup in the early 1980s. Many companies, including MS have developed C++ compilers. As you mentioned in the question, C++ & C# are good for different purposes. C# was an ongoing effort involving VB and the untimely divorce of Sun (Java) and MS. C# and the .Net platform are primarily intended for general purpose application development including desktop and web. C++, also general purpose is better at high performance applications, but not really web.
@lewcreative
@lewcreative Жыл бұрын
Sadly I failed my C++ class. I don't really recommend C/C++ as a first language. I recommend a higher level language then going on to lower level languages. I am now doing well in C and C++. I don't love them like Python or Go or Kotlin, But, the knowledge you get from learning these lower level languages is just addictive and makes you love and appreciate computers on a deeper level.
@lil_brumski
@lil_brumski 4 күн бұрын
Skill issue
@oracleoftroy
@oracleoftroy 2 жыл бұрын
Focusing on memory management misses things a bit. Thinking in terms of resources is more telling. A resource are things that follow an "acquire" and "release" pattern, e.g. a file is "opened" and "closed", a mutex is "locked" and "unlocked", memory is "allocated" and "freed", etc. In C#, the only resource you get automatic cleanup for is memory (through the GC), everything else you have to manually clean up. Using statements help with that, but that is something you have to explicitly remember to use every time you use a resource type. The GC doesn't help with anything else except as a failsafe that you never actually want to rely on. In C++, all resources can be fully automated so that they are always properly cleaned up, not just memory. Doesn't matter if it is a file, socket, transaction, mutex lock, or anything else, when you hit the end of its scope it is automatically cleaned up. C# uses old and busted 1960's GC tech, C++ uses modern 1980's tech with automatic resource management.
@rallolollo9309
@rallolollo9309 2 жыл бұрын
in c++ the automated resource management is a desing pattern.... you have to do everything by yourself also c# has changed the gc very reacently and it's much better
@oracleoftroy
@oracleoftroy 2 жыл бұрын
@@rallolollo9309 The difference is that in C++, you write your destructor once and it works everywhere. In C#, you implement IDisposable once, but you also still have to explicitly use that interface everywhere you handle a resource. Otherwise you leak the resource and have to hope the garbage collector finalizes it in a timely manner. Relying on the finalizer for cleanup is very bad and can be the source of a lot of slowdown with the GC. A properly written Dispose will suppress finalization on the object to avoid the extra overhead. Calling resource cleanup a design pattern is fine, but what that pattern gives you is the key difference. The C# Dispose pattern still requires manual resource management. The C++ rule of five/rule of zero pattern gives you automatic resource management, and does so transitively so that there is zero extra work once the destructor is written.
@rallolollo9309
@rallolollo9309 2 жыл бұрын
@@oracleoftroy yhea but my point stands true, you still have to apply to that pattern everywhere, if you forget to do it you are causing serious problems. instead in c# you can let everything to the gc. My point is not as much as "how much code" do i have to write but instead will someone that never worked on c like languages mess up or not. For example if i would have to choose nowadays between c++ and rust i would probably go for rust for the same reason.
@henrykkaufman1488
@henrykkaufman1488 Жыл бұрын
Id say its easier for any programmer to be successful if he knows about memory and how code is executed. After all, that is what is actually being programmed. Its easier to see a straightforward way to implement stuff if you know this.
@user-sl2sp8jy7b
@user-sl2sp8jy7b 5 ай бұрын
Actually you can force GC to collect earlier if you need in C#
@seanknight9808
@seanknight9808 2 жыл бұрын
So, if I had to choose one to learn, which would it be? What is used more nowadays? Which one is in higher demand? Are they about the same? I heard Python is the most important language nowadays.
@Blaisem
@Blaisem 2 жыл бұрын
In the programming world, people emphasize the slogan "the right tool for the job." This means there is **no** swiss-army programming language that does everything. When you ask for "the one" language to learn, then you are inherently opting into a trade off where you will be most marketable for what that single language provides and not top tier in other contexts. In short, any major language is viable. You can pick one and learn it and get a job. What you may want to ask instead is "which language is the most important for the work _I_ want to be doing?" Ergo, the hard part is actually on you. _You_ need to figure out what it is that you wish to do. After that, a simple Google search will tell you which language is best. What you are trying to do here is ask us what we think you want to do. Obviously, this approach isn't objectively reliable, unless you want superficial reassurances to comfort your indecision.
@elenfoiro78
@elenfoiro78 2 жыл бұрын
A few inaccuracies in the presentation of C++ which I believe comes from a lack of practice. For example, the value vs the reference thing only demonstrate poor understanding of what's really going on under the hood. So interesting video if you're looking for a wrap up of the myths and urban legends about C++.
@ZeroSpawn
@ZeroSpawn 2 жыл бұрын
Nice complaint, but lacking solutions.
@ChoiceOfIllusion
@ChoiceOfIllusion 2 жыл бұрын
3:04 You have completely missed the critical part about the CLR. Yes the C# compiler creates a DLL/EXE (assembly) containing IL code. However the CLR does not actually run IL at all. Instead when a .NET DLL/EXE is first executed the CLR performs Just in Time (JIT) compilation of the IL to machine code and caches that machine code on your computer. It is this machine code that executes. The compilation to machine code is why .NET assemblies are sometimes slower to start up the first time. But from then unless you recompile your c# code, when you run that EXE/DLL it is just the existing machine code file that is being executed. In general machine code execution C# is a only slower than C++ because of the overhead of auto memory management and numerous bounds and other 'safety' checks it adds to the generated machine code. However, because the CLR is platform aware, when JIT compiling it is able to apply various platform specific optimizations to that generated machine code and so performance is improved over standard cross platform generated machine code. If you've worked with C# for some time you really need to understand this. If you're more a C++ dev . fair enough. it is not obvious unless you dig deeper which is why so many are confused. By the way, it is "intermediate language code" in the dll/exe, NOT "intermediate machine code". In context with what I explain above this is extremely confusing for new people. Please don't call it that. See: docs.microsoft.com/en-us/dotnet/standard/managed-code
@bobweiram6321
@bobweiram6321 2 жыл бұрын
C# also compiles to native instructions or AOT.
@McCulloughAssociates
@McCulloughAssociates 2 жыл бұрын
You are totally correct. We didn't want to dive that deep in a short presentation.
@matt-xq1xv
@matt-xq1xv 2 жыл бұрын
Very well put
@clonkex
@clonkex Жыл бұрын
I wish people would emphasise this point more. It's really important to know that C# isn't running in a VM, it runs natively, the same as C++. I see tonnes of C++ devs pile on hate for C# because they mistakenly believe it runs in a VM.
@lionlinux
@lionlinux 2 жыл бұрын
I've started learning c# only after crossplatform version of dot net was populated!!!
@aaronpizarro4216
@aaronpizarro4216 Жыл бұрын
In which language would you reccomend to start? I would like to start my journey in programming with one of this languages
@McCulloughAssociates
@McCulloughAssociates 11 ай бұрын
Learn all of them! ;D Seriously - it really doesn't matter - maybe your job prospects would dictate the starting point. Programming is much, much more that language. The more languages you are fluent in, the better software engineer you will be in all of them. (plus, languages come and go)
@SakraIgor0qNomoko
@SakraIgor0qNomoko 2 жыл бұрын
As a non-programmer, I think someone would have to already know one of the languages (or have taken college classes) to understand most of the terminology you use. Perhaps explaining jargon a bit more would lead to a wider audience appeal.
@chillydill4703
@chillydill4703 2 жыл бұрын
Well, what you are referring to is basic understanding of programming in general, regardless what language it is (python, java, javascript etc..).
@vortex_7574
@vortex_7574 2 жыл бұрын
@@chillydill4703 Agree. My first language was python in college and moving to C++ was seamless. The same went for C# and Java. Mostly the terms changed but the concept was really similar between all.
@chillydill4703
@chillydill4703 2 жыл бұрын
@@vortex_7574 Yep agree!
@broquietstorm1266
@broquietstorm1266 2 жыл бұрын
@@chillydill4703 The question is though, is this video for you guys or is it for someone like the OP? I'm asking because I have no idea and feel the same as the OP.
@chillydill4703
@chillydill4703 2 жыл бұрын
@@broquietstorm1266 Well, personally, I think it's for a beginner turning into an intermediate programmer who already knows the fundamentals of programming but started to explore where improvements could be done, hence looking into these languages.
@unskeptable
@unskeptable 2 жыл бұрын
Nice
@CallousCoder
@CallousCoder 2 жыл бұрын
C++ I want lean binaries without , no runtime environments and that’s truly cross platform. C++ with Qt is a golden combo.
@DmitryBaranovskiyMrBaranovskyi
@DmitryBaranovskiyMrBaranovskyi 2 жыл бұрын
no... at all. Qt is a golden disaster.
@CallousCoder
@CallousCoder 2 жыл бұрын
@@DmitryBaranovskiyMrBaranovskyi why? I adore it. It’s very clear, intuitive and fast. And literally just create a project for that platform and it compiles and runs. That’s pure magic.
@YRBYD
@YRBYD 2 жыл бұрын
I wouldn't call it very clear and intuitive tho. Imgui takes the spot for me in this category
@CallousCoder
@CallousCoder 2 жыл бұрын
@@YRBYD ImGui is only a very simply UI library. Qt is a whole cross platform library, UI is a part of it you can’t compare the two. Qt it’s image processing and 3D abilities are stellar; I used it on Dunkirk and it could do everything out of the box we wanted. Very astonishing! And it’s QSockets make for a truly cross platform socket implementation which otherwise becomes a #ifndef hell. Stuff ImGui can’t do. If you just need a UI (albeit one that’s not using native OS components) ImGui will do the trick.
@BobbyLonely
@BobbyLonely 2 жыл бұрын
to program video games c++ or c# is recommended. I already have basics in programming so I have to choose a language and I don't know which one to choose. :(
@Phroggster
@Phroggster 2 жыл бұрын
C++ vs. C# in the gaming world is kind of a misnomer. Use whichever one you're more comfortable with, or whichever one your game engine makes available to you. In Unity, that's probably going to be C#, Unreal C++ (or blueprints), etc. If you're building one from scratch and are equally fluent in both languages, C++ will give you slightly better performance at the expense of increased code verbosity, while the C# compiler will give you much easier-to-interpret error messages and the language paradigm itself will give you improved code brevity. In the end though, it doesn't really matter to anyone outside of the development team. I've seen games created in Lua or Python that performed better than similar ones written in C++, and it all comes down to your preference. I've also seen people make games in C# to lay out the essential gameplay framework, then switch to hosting that game library within C++ for the more advanced rendering, networking, and compiler optimizations it offers.
@KyleDavis328
@KyleDavis328 2 жыл бұрын
You choose the one being used by the engine you want to use. Unity used C# for scripting, Unreal uses C++ for scripting, other engines use other languages or in many cases offer their own in-house language.
@trickysoft
@trickysoft 2 жыл бұрын
After 40 years of C and 25 of C++ (no C#) the choice for me is a little wider. Including C which on several large projects, I have seriously thought about using and basic C++. I have often worked with very experienced C or VHDL/Verilog programmes who struggle with C++ and have no idea about C#. They can usually transition to the very basics of C++ but get on much better with malloc/free than they do with new/delete and cannot comprehend auto or smart_ptr. It is the hiding of what is going to happen that they usually struggle with and so operator overloading is also a no no except sometimes if it is a straight forward maths type. I would also say that for a simple small app with a short runtime, it doesn't matter. One other think to remember is how much effort is it to deploy whatever runtime is required for the final executable.
@OperationDarkside
@OperationDarkside 2 жыл бұрын
For a second I thought you'd have to have 65 years of programming experience then. Even if you started at the age of 10 you'd be 75 now 😆
@trickysoft
@trickysoft 2 жыл бұрын
@@OperationDarkside Sorry, I should have been more precise, yes, I use C++ much more than C, so it is more like 15 years of C before swapping mostly to C++ for the next 25 years but still doing some debugging and a bit of C coding, well, it has all been pre C99 as I've used VS since it came out. I really used to hate it when I would get a CV from a fresh grad claiming 3 years of C, 3 of C++, 3 of Java ...
@OperationDarkside
@OperationDarkside 2 жыл бұрын
@@trickysoft It's all good :-) I have autism, so I take things very literally quite often. This sometimes leads to hilarious misunderstandings.
@vekmogo
@vekmogo 8 ай бұрын
As a Java programmer, this just makes me want to learn C# in conjunction with Golang.
@jackkayden7559
@jackkayden7559 2 жыл бұрын
What is the best to start to program a game?
@McCulloughAssociates
@McCulloughAssociates 2 жыл бұрын
Use Unity with C# - probably easiest to learn - unity.com/ For C++, use UnrealEngine.com
@lionlinux
@lionlinux 2 жыл бұрын
Looks like commertial for c sharp
@onogrirwin
@onogrirwin 2 жыл бұрын
That intro gave me "Developers, developers, developers, developers!" vibes
@florinf2003
@florinf2003 Жыл бұрын
You can call GC manually in C#.
@Aisaaax
@Aisaaax 2 жыл бұрын
The way I look at it is there is really nothing you can do with c# that you cant do with c++. But there are things that you can do with cpp that you cant do as well wth cs. It doesnt mean that c++ is always better. There are a lot of projects where saving 1ms of speed is completely irrelevant, so you there will be no tangible benefit to c++ over c#. It is a question of whether the developer's time is more valuable than execution time. And sometimes the answer is yes.
@wopmf4345FxFDxdGaa20
@wopmf4345FxFDxdGaa20 2 жыл бұрын
Exactly, good points. It's a question about at which language you are most effective working at and there it also depends about what kind of problem you are solving and what libraries, etc. you have available for that problem in each language. Like a carpenter doesn't do everything with a screwrider when building a house. Instead he uses different tools for different jobs, he uses saw and hammer and etc. In programming there often comes up this not very sensible idea that everything should be done with one language.
@istvanszennai5209
@istvanszennai5209 2 жыл бұрын
7:24 uhm..functional programming is something totally different (C++ and C# are imperative languages). Of course you could say that since C++ template metaprogramming is Turing-complete, you can in fact use templates to write functional programs, but they will be "executed" by the compiler.
@McCulloughAssociates
@McCulloughAssociates 2 жыл бұрын
Agreed C++/C#/Java are not primarily functional. However, the ability to treat a function as an object is an important tool in realizing dependency inversion.
@MrEW1985
@MrEW1985 2 жыл бұрын
First C# and then C++ is the good answer
@JohnWasinger
@JohnWasinger 2 жыл бұрын
5:10 enum types do not have member functions.
@McCulloughAssociates
@McCulloughAssociates 2 жыл бұрын
Correct - a bit of a misstatement. Using helper functions or an enclosing struct or class, we can simulate member functions similar to java.
@tullochgorum6323
@tullochgorum6323 8 ай бұрын
It's not accurate to say that C# offers no control over the GC - there are 8 different methods on offer from C# 10. Plus in many performance critical scenarios it is possible to write allocation-free code. HIghly optimised C# can approach C++ for performance while being safer and easier to write - though obviously managed code can never compete on memory use for embedded applications - that's simply not what it's designed for.
@BasPower12
@BasPower12 6 ай бұрын
C++ better than C# in performance and all other tasks except backend web
@cyrilemeka6987
@cyrilemeka6987 2 ай бұрын
8:28 hah, the standard library laughs in std::basic_stream
@tuterruyi5178
@tuterruyi5178 3 күн бұрын
Well am an c enjoyer Sooo... See more...
@juergenm6107
@juergenm6107 2 жыл бұрын
Good comparison. But at the end it is like comparing apple with pear. You comparing the STL with the whole dotNet Framework. In reality when we take the cross platform capability then there will be no GUI Framework in the dotNet world. For GUI and other missing stuff in the C++ world, you can add e.g. the Qt Framework which has many features you mentioned on the dotNet side. But in the end such comparisons are not very use full. It always depends on the problem you like to solve and which resources you have available.
@Ormaaj
@Ormaaj 2 жыл бұрын
The GUI issue will be solved eventually I think. It isn't a fundamental limitation of dotnet, there's just been a lack of interest in solving some fundamentals correctly. QtSharp's technique for emulating name mangled object code is about the best hack for the moment. It's a symptom of a deeper problem Microsoft has been trying and failing to solve for the last 30 years, because their basic approach is always the same - wrap C++ in an IDL type intermediary like DCOM / CORBA. IDLs are interesting but there's zero interest in building on that in the open source world. I don't think the C++/CLI approach is the right one either. Microsoft was not ambitious enough in building out meta-programming facilities with Roslyn so it fell way short of what it could have been. That's ultimately why you have no GUI, and no successful dotnet ports of mainstream languages.
@marna_li
@marna_li 2 жыл бұрын
In C# everything is an object (with methods and properties), even the value types are - though they get copied when passed around and used as parameters. You can create pointers to value types in an "unsafe" context. System.ValueType, which is the base class of all structs (including primitive types) and enums, inherits from System.Object.
@ToadieBog
@ToadieBog 2 жыл бұрын
Just some clarification, when reference types are passed as parameters, the objects they reference aren't copied, just the references to the objects.
@alphaanar2651
@alphaanar2651 2 жыл бұрын
> In C# everything is an object- Pointers themselves are not objects
@shekcbanny
@shekcbanny 2 жыл бұрын
C# job market wide.
@etaashmathamsetty7399
@etaashmathamsetty7399 2 жыл бұрын
4:48 RIP typedef 6:02 RIP malloc and RIP free
@sdfsdfs13
@sdfsdfs13 2 жыл бұрын
The Multi-Inheritance CHAD vs The Virgin Single Inheritance
@adamodimattia
@adamodimattia 2 жыл бұрын
I've never seen and can't find what means "value" vs "reference" based language, anyone?
@McCulloughAssociates
@McCulloughAssociates 2 жыл бұрын
Great question. In C++, by default, a variable is large enough to hold the data (value) and a copy is passed to functions. emp in the line below is all the memory for employee data and copies are made if passed or assigned in c++. That statement in c# declares a reference, the equivalent of Employee* in C++. C# isn’t pure reference based as primitives have value semantics. Employee emp; In C#, emp is a null pointer (reference) and an object must be allocated from the heap via new. Only the reference is passed or assigned, not copies of the object. Most functions in C++ are defined to pass references or pointers to avoid the cost of making copies, but that requires explicit syntax (* or &).
@jugnu361
@jugnu361 2 жыл бұрын
Nothing Like C++
@Songfugel
@Songfugel 2 жыл бұрын
Yes, then it would just be called C++. However, there are languages that can do what C++ does, C# being one of them, since it is actually extremely close related to it when run in unsafe native mode and precompiled to native at compile time
@MrBlazzerBoy
@MrBlazzerBoy 2 жыл бұрын
Is C# kinda like JAVA?
@maxfrischdev
@maxfrischdev 2 жыл бұрын
Kinda, yes. And java would have been the correct contestant to compare C# to, not C++.. You can compare C++ with Rust for example
@Grimlock1979
@Grimlock1979 2 жыл бұрын
C# 1.0 was like Java but C# has evolved a lot further than Java since then.
@edwinmartens7459
@edwinmartens7459 2 жыл бұрын
C# was/is Microsofts aswer to, and implementation of Java 😉
@wopmf4345FxFDxdGaa20
@wopmf4345FxFDxdGaa20 2 жыл бұрын
@@maxfrischdev You can always compare.
@guilherme5094
@guilherme5094 2 жыл бұрын
👍
@FPChris
@FPChris 2 жыл бұрын
C++ all day
@riOdariot
@riOdariot 2 жыл бұрын
I understood more with your 11mins video than a whole year of C++ at uni.
@Erlisch1337
@Erlisch1337 2 жыл бұрын
obviously not true. you probably would not understand anything of what was talked about here if you hadnt done uni or at least used the languages a bit
@stefanplusplus917
@stefanplusplus917 2 жыл бұрын
@@Erlisch1337 i always apprechiate it when people tone down exaggerated comments. thanks
@software2171
@software2171 2 жыл бұрын
Missing : C# easily reverse engineered and get the source code back but not C++(CLI)
@Cara.314
@Cara.314 2 жыл бұрын
it was not missed. covered about half way in.
@Erlisch1337
@Erlisch1337 2 жыл бұрын
watch the video next time
@mymoney5536
@mymoney5536 2 жыл бұрын
Delphi forever!
@clonkex
@clonkex Жыл бұрын
3:10 No! This isn't true, and it's an important distinction and a common misconception (especially among C++ programmers, for some reason). C# compiles to native machine code, exactly the same as C++. The only difference is that it does it at runtime using the CLR's JIT compiler. There's no VM involved. All C# code runs directly on the hardware, exactly like C++. It just has extra hooks to trigger the compiler (including potentially multiple times).
@McCulloughAssociates
@McCulloughAssociates 11 ай бұрын
Kind-of the definition of virtual machine. The CLR (as well as the Java VM) does cache the native translation at runtime and .Net applications are certainly fast. But the whole idea of "managed code" is that the application runs in a runtime that is on the lookout for common problems like null references and index out of bounds, etc. That does add to execution time. Not saying it's good or bad.
@clonkex
@clonkex 11 ай бұрын
​@@McCulloughAssociates ​It's not though. By that logic, C++ caches the "native translation" when you compile. In that regard, C# is the same as C++ except that it finishes the compilation at runtime instead of ahead of time. It also doesn't run "in" a runtime. It's executed _by_ the CLR, but it's running natively, on bare metal, exactly the same as C++. The CLR is an extra step but not an extra layer. Uncompiled methods are compiled to stubs that call back into the CLR. Once the JIT has completed compilation, it modifies the stub to point to the compiled code and returns execution to the program. The checks and guards (like array bounds checking, which, arguably, a C++ programmer should be doing anyway) are compiled in. It's still native code, just with built-in safeguards. It's also worth noting that the safeguards are not even added when it's statically provable they're not needed. I can't find any definition of VM that fits what C# and the CLR are. It's just a different way of compiling native machine code. I'm not familiar with Java but I would suggest that JVM is a misnomer.
@Antagon666
@Antagon666 8 ай бұрын
Why not learn both ? C++ for low level and C# for scripting and prototyping. They are similar enough.
@kevinstefanov2841
@kevinstefanov2841 2 жыл бұрын
Comparing C++ to C# is like comparing a potato to a cucumber. They're both vegetables but that's about all they got in common lol.
@UlulaSilvia
@UlulaSilvia 2 жыл бұрын
Just one little big problem with C# "windows / microsoft tech only"
@McCulloughAssociates
@McCulloughAssociates 2 жыл бұрын
.Net core runs anywhere. Old .net framework is obsolete
@magburner
@magburner 2 жыл бұрын
An inexperience programmer can tell you this. C++ is cloers to C in its nature. C# is closer to Java in its nature. The only thing both programming languages have in common is the letter C.
@Cara.314
@Cara.314 2 жыл бұрын
all 4 share a similar syntax. c# also has a considerable subset of features that bring it closer to c than java.
@asanstudio
@asanstudio 2 жыл бұрын
Thank you. This explain why Unity is much slower than Unreal.
@Aidiakapi
@Aidiakapi 2 жыл бұрын
Most of Unity is written in C++. Unity is much slower than Unreal, but it's not C# that's to blame, it's Unity.
@bobweiram6321
@bobweiram6321 2 жыл бұрын
C# is a highly productive, versatile and joy to program in, but it is despised because it's Microsoft. C# can also be compiled (AOT) on all platforms.
@tordjarv3802
@tordjarv3802 2 жыл бұрын
While it is true that you can compile C# programs for non-M$ platforms, it is generally a terrible experience and you are limited to older versions of C#. If you don't want to develop for M$ platforms (i.e. Windows and XBox) I would suggest not using C#, personally I would suggest Kotlin as a good alternative to C#.
@McCulloughAssociates
@McCulloughAssociates 2 жыл бұрын
.Net Core (modern c#) is run-anywhere. And if you consider Xamerin or Maui, you can cross compile for android and IOS.
@Aidiakapi
@Aidiakapi 2 жыл бұрын
C# is consistently rated as one of the most loved languages out there, so calling it despised is a bit excessive.
@Aidiakapi
@Aidiakapi 2 жыл бұрын
@@tordjarv3802 The headaches you have running JVM based code everywhere isn't too dissimilar from running .NET based code everywhere. In the end, they're both rather easy to run cross platform nowadays, but each have their flaws.
@tordjarv3802
@tordjarv3802 2 жыл бұрын
@@Aidiakapi Who calls C# despised?
@edwinmartens7459
@edwinmartens7459 2 жыл бұрын
Raw pointers don't cause problems, bad programmers do... 😏
@wopmf4345FxFDxdGaa20
@wopmf4345FxFDxdGaa20 2 жыл бұрын
It's a game of probability. If there is a chance to make an error, the error will be made at some point by someone.
@gondoravalon7540
@gondoravalon7540 2 жыл бұрын
@@wopmf4345FxFDxdGaa20 I do wonder though if that is the programmer, the language, how the project is organized, or a combination of factors.
@wopmf4345FxFDxdGaa20
@wopmf4345FxFDxdGaa20 2 жыл бұрын
@@gondoravalon7540 Very valid question, it is a combination of those factors. 😉
@DefaultGuy84
@DefaultGuy84 7 ай бұрын
exactly
@wastedkafir9134
@wastedkafir9134 2 жыл бұрын
*want to become a programmer and write code that runs faster with less memory go for c/c++ else go for any of the script writers language c#, java, Borneo, Sumatra and what not*
you will never ask about pointers again after watching this video
8:03
Low Level Learning
Рет қаралды 2 МЛН
Зу-зу Күлпәш. Стоп. (1-бөлім)
52:33
ASTANATV Movie
Рет қаралды 1,2 МЛН
顔面水槽がブサイク過ぎるwwwww
00:58
はじめしゃちょー(hajime)
Рет қаралды 115 МЛН
[Vowel]물고기는 물에서 살아야 해🐟🤣Fish have to live in the water #funny
00:53
Why i think C++ is better than rust
32:48
ThePrimeTime
Рет қаралды 263 М.
Rust vs C++
7:18
conaticus
Рет қаралды 48 М.
C++ for C# and Java Developers
39:47
ABMedia
Рет қаралды 22 М.
31 nooby C++ habits you need to ditch
16:18
mCoding
Рет қаралды 711 М.
how Google writes gorgeous C++
7:40
Low Level Learning
Рет қаралды 744 М.
I Tried C#
4:32
conaticus
Рет қаралды 225 М.
Comparing C to machine language
10:02
Ben Eater
Рет қаралды 5 МЛН
Getting into Game Programming with C# or C++
6:21
Stefan Mischook
Рет қаралды 199 М.
Is C# Better than Java?
18:41
Gavin Lon
Рет қаралды 11 М.
На iPhone можно фоткать даже ночью😳
0:30
GStore Mobile
Рет қаралды 1,4 МЛН