Home arrow JavaScript arrow Page 6 - JavaScript Operators
JAVASCRIPT

JavaScript Operators


You can't do much with a programming language without operators. JavaScript is no exception. So this article will introduce you to JavaScript operators and what you can do with them.

Author Info:
By: James Payne
Rating: 4 stars4 stars4 stars4 stars4 stars / 3
November 05, 2007
TABLE OF CONTENTS:
  1. · JavaScript Operators
  2. · Arithmetic Operators
  3. · Assignment Operators
  4. · Add and Assign
  5. · Comparison Operators
  6. · Logical Captain?

print this article
SEARCH DEVARTICLES

TOOLS YOU CAN USE

advertisement
JavaScript Operators - Logical Captain?
(Page 6 of 6 )

Spock was a walking computer. You could ask him the chances of anything and he would know.

*Impersonating Kirk*: What are the chances of that guy..in...the red shirt getting........shot?

Spock: 100%

*Impersonating Kirk*: What are the chances of a computer nerd having a date this weekend...not involving...other nerds?

Spock: -100%

That was a good episode. And by the way, J.J. Abrahms if you are reading this, I am totally available to write the next Star Trek script or even an episode or 400 of Lost.

There are three logical operators in JavaScript. They are the && (AND), the || (OR) and the ! (NOT). There is technically a fourth, the ?: (Ternary) but we won't be focusing on that one.

Again, logical operators are mostly used for statements. The && operator says that this and that must meet the criteria, while the || states that either this or that must meet the criteria. And finally the ! operator says that the criteria is not equal to this or that.

While there are more operators in JavaScript, these are the most common.

Well slackers, that is it for this lesson in JavaScript. Join us next time as we discuss Pop-Up Boxes, Functions, and maybe even Loops.

Till then....


DISCLAIMER: The content provided in this article is not warranted or guaranteed by Developer Shed, Inc. The content provided is intended for entertainment and/or educational purposes in order to introduce to the reader key ideas, concepts, and/or product reviews. As such it is incumbent upon the reader to employ real-world tactics for security and implementation of best practices. We are not liable for any negative consequences that may result from implementing any information covered in our articles or tutorials. If this is a hardware review, it is not recommended to open and/or modify your hardware.

blog comments powered by Disqus
JAVASCRIPT ARTICLES

- More Top jQuery Tutorials for Beginners
- More Top jQuery Plugins for Menus
- Top jQuery Tutorials for Beginners
- New UI Framework and SDK for JavaScript Rele...
- JavaScript OpenPGP Tool, Node.js 0.6.3 Avail...
- Yahoo Releases Cocktails Language and Develo...
- Customizing jQuery Slideshows: Dynamic Contr...
- Customizing jQuery Slideshows: the animate()...
- Customizing jQuery Slideshows: slideUp() and...
- Customizing jQuery Slideshows: hide() and sh...
- Web Workers: Performing Calculations in Para...
- More Top JavaScript Frameworks and Libraries
- More Dynamic jQuery Styling Techniques
- The Top JavaScript Libraries
- The Top JavaScript Frameworks

Dev Articles Forums 
 RSS  Articles
 RSS  Forums
 RSS  All Feeds
Weekly Newsletter
 
Developer Updates  
Free Website Content 
Contact Us 
Site Map 
Privacy Policy 
Support 



© 2003-2012 by Developer Shed. All rights reserved. DS Cluster 4 - Follow our Sitemap
Popular Web Development Topics
All Web Development Tutorials