Research Paper Week 2: Visual Basic and Java
Variable naming rules differ from each program language that a user uses. To remember each and single one for each program language is insane. Looking at Visual Basic and Java one can see the small difference in the rules.
Visual Basic is considered to be the beginner’s program language uses variable names that would make sense to anyone who can speak Basic English. First off Visual Basic is not case-sensitive like some programming languages. One must use a letter as the first character and the name can’t exceed 255 characters in length. The use of space, period, and exclamation mark in the name is not allowed. Users also cannot use special characters in the naming of variables. (Visual Basic Naming Rules, 2011)
Java unlike Visual Basic is considered to be a more advance programming language. The name rules are slightly different in that one can use letters, underscore, or a dollar sign to start the naming process. Even though you can use underscore and dollar sign it is not seen as a good practice. Also unlike Visual Basic the user is can use as many characters as they would like to name a variable. Java is case-sensitive, meaning that Uppercase characters are different the Lowercased character giving the user more options in naming. Java keywords for variable names are reserved, unlike Visual Basic where it was bad practice to use keywords. (Beginning JAVA, n.d.)
In the great world of programming, it is important to remember what language one is working with to ensure that the proper naming rule is being applied. There is nothing worse than writing a whole program using the wrong naming rules.
Beginning JAVA. (n.d.). Retrieved from mathbits.com: http://mathbits.com/MathBits/Java/DataBasics/Namingrules.htm
Visual Basic Naming Rules. (2011, December 6). Retrieved from Office Dev Center: http://msdn.microsoft.com/en-us/library/office/gg264773.aspx