Why is the C language considered to be a medium-level language?

Asked

Viewed 295 times

0

The C programming language is considered a mid-level language. Why?

  • I think this can help you: https://answall.com/questions/57309/o-que-faz-uma-linguagem-ser-considerada-low-down%C3%advel/57314#57314

  • 1
  • Did the answer solve your question? Do you think you can accept it? See [tour] if you don’t know how you do it. This would help a lot to indicate that the solution was useful for you. You can also vote on any question or answer you find useful on the entire site (when you have 15 points).

1 answer

5

Give a reference that this is true. And define what is medium level.

There is no language level

This language level cosia is complicated and there are controversies of what is low or high level, worsened trying to find a limit to what is medium level.

One might say it is, but it’s not easy to say why it is, what makes language come out of one of the two extremes and be mid-level.

People I know treat C as high-level language, even though that level is not that high.

So by not being so tall someone means she’s middle-class.

By the definition I use the language has lower or higher levels, but saying which is this exact level is more complicated. It’s not like digital, it’s more like analog, it has many gradations to create stop marks.

Examples

Within this it is only clear how low level the Assembly, the language you have to say what to do directly for the processor to do. Even this can be contested because directly only using binary language. In Assembly there is a one-to-one ratio of what the processor will do, but there will still be some writing translation for what the processor understands. So some people might say that the Assembly is medium level and low would be the binary, if that medium level exists. I do not know, there is a formalization on the subject.

C is a programming language like any other that everyone knows. The distance to C or Python is much smaller than what lay people believe.

In fact C is lower level than Python, but it is still very high level. C requires you to take care of certain issues that Python makes automatic for you.

A Programming language is low level when its Programs require Attention to the irrelevant.

-- Alan Perlis

So the more the language requires you to worry about the irrelevant the more it is low-level, the more automatic it is in picking up the intention than it runs, i.e., the more expressive it is, the higher level it is.

I’m not saying that’s the best definition of all, but it’s a good one.

In this criterion C is a little lower level because it requires you to tell the data types, and manage the memory. In addition you have to use array for any data collection without being too specific, you don’t encapsulate anything. So, yes, that’s not very high level.

All the other languages could be a little higher level, but they’re far from such a high level, the really high level would require the languages to be very fluent, which you said roughly and everything would happen.

The level difference between C and Python is very small. Can you say that it is medium level because of this? I think it is not the end of the world, but I think it is complicated to make such a statement, for me it is high level, but in the mucho, that’s all.

Wikipedia

Let’s look at Wikipedia, although there’s a lot wrong there, it’s not always a good reference, especially in subjects of this type where there’s not much formalization, there’s a lot of speculation, but it’s a reference that can be used to get an idea, just don’t take it for granted. She puts Assembly as low level.

It doesn’t specifically speak of C being, but the next level spoken there is the high level. Has no middle level.

What exists is an even higher level, the highest level (which is the only place I’ve ever seen talk about it), and seems to establish which languages of script are like that. And that turns out to be a problem because these languages, unlike the Dsls where the term would have started, have nothing much more abstract than other languages, and these same languages have tried to change their philosophy.

I used this to try to show that it doesn’t have a good definition, not to show that C is medium or low or medium level, nobody knows for sure and doesn’t matter, just as it matters even less what generation the language is. And for me the definition of "higher level" is the same as in the languages of 5th. generation, that is, there is a lot of nonsense in this.

Trying to give levels to languages

We can say that language is of high level when it is close to human understanding. I show Python to some people and they say they are seeing Russian mixed with Greek. I show C to any programmer and they understand what is there, even if they need to explain one or another syntax point. This does not happen with Assembly. So C is very understandable to a human with real knowledge about programming.

The same code written completely in C++ can be less understandable for having too much abstraction, although everyone agrees that it is more expressive and so would be more at the high level.

Another definition says that the language needs to access the hardware more directly. Does that make C lower level? Assembly allows exactly the same level. C# is almost the same. They are all at the same or almost the same level?

C prefers you to create your abstractions than deliver them ready. And it doesn’t give many mechanisms to create abstractions that are imperceptible. But it’s very different from being completely concrete. Then the medium might come from there.

But how would C++? It allows and delivers much more abstraction, avoids you taking care of the irrelevant. But it allows you to make the most concrete, manage every detail, even by being quite compatible with C. So C++ is what?

And Rust?

Java and mostly C# allows almost everything C allows, but delivers a more abstract and controlled standard way.

Languages of script are higher level then? Have you seen Perl? No one understands that.

COBOL would have a very high level for being so verbose?

Completion

Before classifying languages by their level we need to find a consensus of what each level is and it doesn’t even exist.

In that reply has a reference of where the medium level came out. Anyone can write whatever they want, the paper and HTML accept everything. Just because someone in Rio Grande do Sul or elsewhere writes that she is medium level means that she is. At least the quote used is very confusing, it doesn’t seem like the person knows what they’re saying and she doesn’t explain that.

I won’t explain what I won’t even agree is true.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.