Author Topic: different languages pros and cons???  (Read 711 times)

daydreamer

  • Member
  • ****
  • Posts: 942
  • watch Chebyshev on the backside of the Moon
different languages pros and cons???
« on: September 15, 2019, 06:42:10 AM »
https://www.webdesignerpad.com/2018/02/the-future-of-the-c-programming-language.html
so what about asm,C/C++,C# and basic's and python pros and cons
what your thoughts?
Quote from Flashdance
Nick  :  When you give up your dream, you die
*wears a flameproof asbestos suit*
Gone serverside programming p:  :D

jimg

  • Member
  • ***
  • Posts: 349
Re: different languages pros and cons???
« Reply #1 on: September 15, 2019, 07:31:58 AM »
You can do just about anything with any language if you try hard enough.   For me, I like language that I like the syntax of, not all it's hype.  If the syntax sucks, I avoid it like the plague.

hutch--

  • Administrator
  • Member
  • ******
  • Posts: 6758
  • Mnemonic Driven API Grinder
    • The MASM32 SDK
Re: different languages pros and cons???
« Reply #2 on: September 15, 2019, 01:18:20 PM »
Magnus,

What you have to watch with a language like C# is how long it will be around. The folks who used Visual Basic learned the hard way when all the techniques they had learnt over the years became useless when Microsoft dumped the language and produced a crapheap VBnet. While languages like C have been around for a very long time and has a massive user base and every processor family has its own flavour of assembler, many of these boutique languages fall by the wayside. I inherited an old joke from a friend of mine back in the middle 1990s.

Q. What does a C programmer say to an ADA[tm] Programmer ?
A. I will have onions with my french fries please.

BASIC was originally used as a learner language and various dialects have developed over time that were a lot more powerful than the toothless terror of old but it has never been all that portable and some of the dialects were badly designed with patronising assumptions about the skills of the users, much like C# of today.
hutch at movsd dot com
http://www.masm32.com    :biggrin:  :skrewy:

TimoVJL

  • Member
  • ***
  • Posts: 476
Re: different languages pros and cons???
« Reply #3 on: September 15, 2019, 07:39:25 PM »
A simple C program to list Clr files.
usage: PEFindClr.exe C:\Windows\system32\*.*

EDIT: recursive version
usage: PEFindClrs.exe C:\Windows\system32
« Last Edit: September 15, 2019, 10:30:21 PM by TimoVJL »
May the source be with you

LiaoMi

  • Member
  • ****
  • Posts: 593
Re: different languages pros and cons???
« Reply #4 on: September 15, 2019, 07:50:57 PM »
An article without facts, to know how to write correctly and quickly with C#, you need to know the architecture, C# is a variation of Java, everyone knows how strong Java is. I like the flexibility of architecture in C#, where you can write code as fast as in C. But as with c++, there are features  :biggrin: that can affect speed slowdowns. System programming is also no problem, you can make an interface for any library from C++ or assembler, even use the internal windows system libraries. C++ has its advantages and disadvantages, C# does not have these weaknesses due to architecture. I like not only the set of functionality of this language, but also the ability to work with pseudocode, functions can be quickly rebuilt, the possibility of just in-time interpretation opens up a whole new field for smart code. In addition, you can generate code for other languages, for example in javascript. This whole transformation of program code to IR (Intermediate Representation) just increases flexibility. Each language will have its own niche. Every day I never cease to be amazed at the possibilities of this language and in combination with others, makes it perfect in my eyes. Another interesting fact is that it is the fastest growing language. C# will become a similar base language, as well as C for system programming  :tongue:

jj2007

  • Member
  • *****
  • Posts: 9795
  • Assembler is fun ;-)
    • MasmBasic
Re: different languages pros and cons???
« Reply #5 on: September 15, 2019, 08:43:12 PM »
If the syntax sucks, I avoid it like the plague.

Right! That's why I like BASIC: Print "Hello World"

A simple C program to list Clr files.
usage: PEFindClr C:\Windows\system32\*.*

Pelles C first asks me if I want to upgrade the project (which I did), then it tells me POLINK: fatal error: File not found: 'msvcrt.lib'.

Which probably means that I need to set some environment variable to make this compile :sad:

I have lots of C files that compile just fine with Pelles C 9.0, so no idea why this one fails. And I won't investigate.

Honestly, a big thank you to Hutch for his decision to use \Masm32 as the path in the SDK. Simple and intuitive syntax is one thing, but the biggest problem of the C/C++ family is its horrible fight with "toolchains" and with path settings etc.

Whenever I make a little excursion into the C/C++ jungle, I find "projects" (ridiculous collections of tiny little files that spit out "hello world" or do similar simple things) that inevitably fails with some error message in M$ VC, and another error message in GCC, and yet another one in Pelles C. The C language is supposed to be a "standard", "compatible" within its family, and even "portable" between OSes. Nope, the Internet is full of desperate requests by C programmers unable to interpret cryptic error messages and hoping that among the Millions of programmers using this marvelous language there may be somebody who invested some nights of hard work to solve the mystery.

It even spits over to languages like Free"Basic" that rely on a C compiler. The FB forum is crammed full of threads that serve no other purpose than to find out why a particular little proggie doesn't compile with this or another "toolchain".

Explore \Masm32\Examples\*.asm. Some of that stuff is 20 years old. I open a file in my editor, hit F6, and it assembles in milliseconds and greets me with a "hello world" or whatever. It works, thanks to this utterly unconventional and "unprofessional" decision by Steve Hutchesson to send environment variables to the dustbin of history, and base everything on \Masm32.

Btw same for GfaBasic, which I used extensively for over a decade until 16-bit became obsolete. I never ever had a problem with paths or "toolchains". It just did his job. Amazing, isn'it? So unprofessional.

AW

  • Member
  • *****
  • Posts: 2435
  • Let's Make ASM Great Again!
Re: different languages pros and cons???
« Reply #6 on: September 15, 2019, 09:47:23 PM »
Well, there are well over 1000 programming languages and growing,
https://en.wikipedia.org/wiki/Lists_of_programming_languages
But they are just tools and 99% of them bring nothing new or benefit over already existing ones.

My personal opinion is:
I like .Net languages for websites, I don't like them for desktop development because are slow and easily cracked, if we want to sell applications built with them.
I like C/C++ and ASM but I believe they are not suitable to produce large stand alone applications unless we have a large dedicated development team. We can integrate C/C++/ASM modules though.
Since last century, I have done large applications in Delphi. They do as low level as C but are developed tens of times faster. They are a little slower than C, but fast enough for what is required. I keep cashing in with some of them and have no plans or incentive to look for better tools.

TimoVJL

  • Member
  • ***
  • Posts: 476
Re: different languages pros and cons???
« Reply #7 on: September 15, 2019, 09:50:22 PM »
A simple C program to list Clr files.
usage: PEFindClr C:\Windows\system32\*.*

Pelles C first asks me if I want to upgrade the project (which I did), then it tells me POLINK: fatal error: File not found: 'msvcrt.lib'.

Which probably means that I need to set some environment variable to make this compile :sad:

I have lots of C files that compile just fine with Pelles C 9.0, so no idea why this one fails. And I won't investigate.
Pelles C just don't have msvcrt.lib, just remove msvcrt_main.c from project or create a new project without it.
May the source be with you

daydreamer

  • Member
  • ****
  • Posts: 942
  • watch Chebyshev on the backside of the Moon
Re: different languages pros and cons???
« Reply #8 on: September 15, 2019, 10:04:22 PM »
I have tried the UWP with C++ and it offers to compile to 4 different cpus,x86,x64,ARM,ARM64 and I realize its a waste to learn all kinds of ASM,when I want to try make something for different hardware than the good old PC with windows
maybe C# is better alternative to this?

Quote from Flashdance
Nick  :  When you give up your dream, you die
*wears a flameproof asbestos suit*
Gone serverside programming p:  :D

AW

  • Member
  • *****
  • Posts: 2435
  • Let's Make ASM Great Again!
Re: different languages pros and cons???
« Reply #9 on: September 16, 2019, 01:55:22 AM »
UWP is dying (like many other Microsoft experiments). For cross platform development try Javascript  (the real cross plaform "assembly language"  :badgrin:) and develop for desktop, web and mobile on every CPU.

https://mspoweruser.com/uwp-is-dead-because-windows-apps-are-dead/

hutch--

  • Administrator
  • Member
  • ******
  • Posts: 6758
  • Mnemonic Driven API Grinder
    • The MASM32 SDK
Re: different languages pros and cons???
« Reply #10 on: September 16, 2019, 02:06:21 AM »
Every tool has its place but they don't all have the same place, if you want to write code that builds on many different platforms, use C, to a lesser degree C++ and if you want to write scripting languages that are portable across different OS types, you can use stuff like JAVA, JSCRIPT, PERL, PHP etc .... but if you want to write code for the major OS version, Windows, you use a low level compiler or assembler and you will get the power and performance.

As far as programming environments on a Windows box, when you have multiple language installations, you really don't want a common set of compilers, linkers, resource compilers and libraries as they are not compatible. On this box I have VC2003, the most current 64 bit VS, 32 bit MASM and 64 bit MASM and they all live in their own worlds without interconnection. I use a couple of BASIC compilers as well but they don't use any of the Microsoft tools apart from the resource compiler.

The factor with all of them is they are all in separate environments that don't have any inter-dependence, keeps the world simple.  :thumbsup:
hutch at movsd dot com
http://www.masm32.com    :biggrin:  :skrewy:

felipe

  • Member
  • *****
  • Posts: 1249
  • Eagles are just great!
Re: different languages pros and cons???
« Reply #11 on: September 16, 2019, 11:15:41 AM »
I don't want to fight with anybody here, i totally respect your opinions. Personally, i think all high level languages sucks, the world would be better if everybody was programming in assembly... :biggrin:
Felipe.

hutch--

  • Administrator
  • Member
  • ******
  • Posts: 6758
  • Mnemonic Driven API Grinder
    • The MASM32 SDK
Re: different languages pros and cons???
« Reply #12 on: September 16, 2019, 11:41:55 AM »
 :thumbsup:
hutch at movsd dot com
http://www.masm32.com    :biggrin:  :skrewy:

anta40

  • Member
  • ***
  • Posts: 309
Re: different languages pros and cons???
« Reply #13 on: September 16, 2019, 04:22:33 PM »
For cross platform development try Javascript  (the real cross plaform "assembly language"  :badgrin:) and develop for desktop, web and mobile on every CPU.

Yep.
I know some people don't like JS, but it's the only cross platform lang these days.
Java failed to do that.

TimoVJL

  • Member
  • ***
  • Posts: 476
Re: different languages pros and cons???
« Reply #14 on: September 16, 2019, 06:56:15 PM »
JXcore
ChakraCore
Code: [Select]
console.log("Hello, World!");
I don't want to fight with anybody here, i totally respect your opinions. Personally, i think all high level languages sucks, the world would be better if everybody was programming in assembly... :biggrin:
:biggrin:
« Last Edit: September 16, 2019, 10:43:34 PM by TimoVJL »
May the source be with you