As you can probably tell, I’ve been out of the loop for a while. I haven’t been feeling up to doing much in the past few weeks other than work and some gaming. This is an article I’ve been meaning to get to for some time: actual discussion of programming languages.

This website is a lot more generalized that the name implies. Originally the site was intended to be called jrConway Programming and Development; this would’ve probably fit better, and there are more steps to development than just programming. Most of what I have discussed so far is about things related to programming, such as creating a website using a web application; a content management system.

Programming is a fairly broad term, and there are many mixed feelings as to what constitutes actual programming and a full-on programming language. There are also computer languages related to programming, but they aren’t specifically programming languages persay. Let’s start by discussing markup.

Markup Languages

This is an example of some basic markup, although there's also some PHP code mixed in here.

This is an example of some basic markup, although there’s also some PHP code mixed in here.

A markup language is used to format data in an orderly fashion. When you’re building a basic website, you’re not really programming, you’re using markup (HTML) and c

ascading style sheets (CSS) to format the markup. Obviously, this is not considered programming, so markup is not a programming language. Markup is often affected by programming languages, though.

GML, SGML, HTML, XML, and XHTML are all considered markup languages. GML and SGML I have only heard of recently, but they’re the foundations of all markup languages. HTML, or hypertext markup language, is by far the most commonly used markup language today. As a web developer I naturally use HTML all the time, although typically you generally don’t spend as much time in HTML as you are in CSS, Javascript, or backend programming languages like PHP.

Just of note, the screenshot above is of this theme’s header file located on Github. You can see some PHP tags in there which appear to be markup, but they are not mark markup at all, so don’t mistake PHP for markup. Several progr

amming languages can be inserted into HTML such as PHP and ASP, but that’s only a few things here and there; most PHP code is all stored in separate files.

Scripting Languages

Javascript is generally considered a scripting language, but its still a programming language all the same.

Javascript is generally considered a scripting language, but its still a programming language all the same.

Although many would argue this with me, a scripting language is merely a type of programming language. Typically, when writing out code it is considered a script if it is under a few thousand lines of code. It is very, very difficult to accurately describe a true scripting language, and reading up articles online, the lines between scripting and programming languages are really blurred so much that it really comes down to personal preference.

Some argue that scripting languages must be compiled. A question I found on StackOverflow addresses this issue quite a bit. Numerous comments throughout the article describe the situation. Languages that are traditionally compiled are often called programming languages, and languages that are traditionally interpreted are called scripting languages. However, any of these languages can be either compiled or interpreted, so there’s really no different whatsoever between scripting and programming languages.

This is a touchy subject with me, as my primary programming languages are PHP and Javascript. Traditionally, both languages are interpreted (ASP and Perl are as well, though I don’t use those) and therefore are not considered programming languages by a lot of people. I don’t really see the difference. Javascript, perhaps, as its primarily used for frontend development and enhancing the frontend experience on the web and even has “script” in the name. However, there’s been a huge surge of using Javascript for backend development as well.

So What Constitutes a Programming Language?

gh_jrconway_jrcron-migration

PHP is a programming language, and is also considered a scripting language, too.

This has been a hard question to find an accurate answer to. At least for trying to back up my evidence with facts online. From what I know, though, programming languages have to have logic. You have to be able to perform mathematical calculations, run loops, make conditional branches, and store variable, among other things. Believe it or not, there’s a startling number of people who honestly believe that html is a programming language.

Can HTML run loops? Can HTML create variables? Can HTML perform mathemetical calculations? Can HTML process data from its own inputs?

The answer? No to all of the above.

If you want to run loops in HTML, you have to use PHP or ASP. Both can be used to create variables and reuse them as well. HTML has input forms, but HTML cannot use them; the only way to use them is to process the form data in either PHP or ASP, or even other server-side programming languages.

Some argue that programming languages need to be object-oriented. I’d say that’s stretching it. JavaScript is even more object-oriented than C is, and C is still considered a programming language. Typically its better to have object-oriented programming languages, but its not a requirement, and even then, it is proven that JavaScript can be object-oriented; its just more difficult and complex to do so than other languages such as PHP or Java which have easy classes built in.

The top ten most popular programming languages on Github has Javascript, PHP, and Perl. ASP is even #15. Javascript is actually #1. Clearly Github considers scripting languages as programming languages. Most lists of top 10 programming languages I’ve found also list scripting languages in them, and Wikipedia lists them as well.

After searching I finally found what I was looking for; TIOBE’s list of the most popular programming languages. Trying to find an irrefutable source unfortunately has been cumbersome, and some lists I’ve found even list SQL and HTML in the lists of top ten programming languages! Yeah, I love both HTML and SQL, and they’re incredibly useful languages for creating websites and web applications. But they’re NOT programming languages no matter how much you want them to be.

As for scripting languages… there are numerous debates about it, but the general consensus is that they are programming languages. In fact, there’s not much different between scripting languages and programming languages other than how they are traditionally used; interpreted or compiled. Both can be interpreted or compiled, though. And all programming languages are made for specific purposes.

Among the most versatile programming languages, though, is Javascript. Javascript is by far the most versatile, despite what it may seem. Its the most popular language on Github and is used for advanced website functionality, online games, and can even be used for backend development, despite PHP being the most popular language for backend development on the web.