c-like

Return type polymorphism in C-like languages

Why don't we see C-like languages that allow for callables with polymorphism in the return type? I could see how the additional type inference would be a hurdle, but we have plenty of languages with full-fledged type inference systems (that work for varying levels of "work"). Edit: By return type polymorphism I mean overloading the func...

Where can I find the source code of C++'s generic.h?

At present, I'm using a C-like language (NXC) to control a LEGO MINDSTORMS robot. That C-like language doesn't have support for generics (or, not being C++, classes. But I digress). However, I read in an outdated C++ book that either C or C++ has a file called generic.h, which contains helpful preprocessor macros (ie name2 and declare) f...

Should I use early returns in C#?

I've learned Visual Basic and was always taught to keep the flow of the program without interruptions, like Goto, Exit and Return. Using nested ifs instead of one return statement seems very natural to me. Now that I'm partly migrating towards C#, I wonder what the best practice is for C-like languages. I've been working on a C# project...

Like freopen and scanf in c#

Who knows the freopen and scanf function functionality but in c# not in c??????? thanks ...