Coding Bootcamp Prep for New Students
How to Prepare for Coding Boot Camp
October 4, 2018
MVC stands for Model-View-Controller
Tutorial: Create an ASP.NET MVC Web App in C# using Database First Approach
October 4, 2018

Learn to code!

What does an exclamation mark mean in programming?

As a child, you began learning the basics of the English language. You learned of the parts of speech, such as nouns, verbs, and adjectives. You began to expand your vocabulary and you were taught sentence structure and how to correctly structure a paragraph. But before any of that, you learned basic punctuation. Without the correct usage of basic punctuation, the rest of your writing loses it’s value and even more so, the message of the writing can become lost.

Punctuation also plays a vital role in how effective your code is. A missing quotation mark, semicolon, question mark, or even exclamation point could prevent your code from functioning as expected. Lets take a look at the exclamation point as an example. When referring to the exclamation point in code, it can also be called a bang.

Here are a few examples of how a bang can be used in code:

<!- -Having the less than sign, a bang, and hyphens signifies the start of a comment in HTML. Without the bang being present or placed in the correct position, the browser will have no way of knowing that this is supposed to be comment.- ->

In the  Javascript and C# programming languages, a bang is used as a conditional operator meaning “not” or “not equal to” if directly followed by an equal sign.

So, whether you call it a bang or an exclamation point, punctuation is just as important in your code, as it is in the English language.


Learn to Code



Comments are closed.

X
X