A language term.

Syntax is the collection of rules defining the correct grammatical arrangement of words within a sentence. "The big dog is sleeping." is syntactically correct, "Dog big sleeping is" is not correct (unless you are Yoda).

The word 'syntax' is often used to describe the rules for putting together a correct computer language statement. For example the correct syntax for setting a variable might be:-

var x = 3;

If the semi-colon is missing or the keyword 'var' is misspelt then the compiler will throw a 'syntax error' to let the programmer know she has made an invalid statement. Part of the effort to learn a new computer language is to remember its syntax.

Challenge see if you can find out one extra fact on this topic that we haven't already told you

Click on this link: Syntax


back to glossaryback to glossary