100% satisfaction guarantee Immediately available after payment Both online and in PDF No strings attached 4.2 TrustPilot
logo-home
Class notes

Java script for begginers

Rating
-
Sold
-
Pages
10
Uploaded on
25-02-2023
Written in
2022/2023

JavaScript is a programming language that enables you to create dynamic, interactive web pages. JavaScript is easy to learn for beginners and has many advanced features for experienced programmers. This tutorial will teach you the basics of JavaScript, including how to write code, execute scripts, and use JavaScript libraries.

Show more Read less
Institution
Course









Whoops! We can’t load your doc right now. Try again or contact support.

Written for

Course

Document information

Uploaded on
February 25, 2023
Number of pages
10
Written in
2022/2023
Type
Class notes
Professor(s)
Sudha agarwal
Contains
All classes

Subjects

Content preview

INDEX

Introduction JS Math

JS Syntax JS Dates

JS Statement JS Arrays

JS Comments JS Comparisons

JS Variables JS Conditions

JS Operators JS Loops

JS Arithmetic JS Type Conversion

JS Data Types JS Regular Expressions

JS Functions JS Debugging

JS Objects JS Hoisting

JS Scope JS Strict Mode

JS Events JS Forms

JS Strings JS Objects

JS Numbers JS DOM

JS Browser BOM




WHAT IS JAVASCRIPT
JavaScript is:
Is a lightweight, interpreted programming language.
used to create interactive effects within web browsers.
Designed for creating network-centric applications
Complementary to and integrated with Java
Complementary to and integrated with HTML
Open and cross-platform
JAVASCRIPT SYNTAX
A JavaScript consists of JavaScript statements that are placed
within the <script>... </script> HTML tags in a web page.

, The <script> tag alert the browser program to begin interpreting all the text between these tags
as a script. So simple syntax of your JavaScript will be as follows
JAVASCRIPT IN <HEAD> OR <BODY>
Scripts can be placed in the <body>, or in the <head> section of
an HTML page, or in both.

External JavaScript:
Scripts can also be placed in external files.
External scripts are practical when the same code is used in
many different web pages.
JavaScript files have the file extension .js.
<!DOCTYPE html>
<html>
<head>
<script src="firstScript.js"></script>
</head>
</html>
EXTERNAL JAVASCRIPT ADVANTAGES
Placing JavaScript in external files has some advantages:

It separates HTML and code
It makes HTML and JavaScript easier to read and maintain
Cached JavaScript files can speed up page loads

JAVASCRIPT FUNCTIONS AND EVENTS
A JavaScript function is a block of JavaScript code, that can be
executed when "asked" for.

For example, a function can be executed when an event occurs,
like when the user clicks a button.
SEMICOLONS ARE OPTIONAL
Simple statements in JavaScript are generally followed by a
semicolon character, just as they are in C, C++, and Java.

JavaScript, however, allows you to omit this semicolon if your statements are each placed on a
separate line. For example, the following code could be written without semicolons


<script language="javascrip”>
<!–
var1 = 10 var2 = 20
//--> </script>

CASE SENSITIVITY
JavaScript is a case-sensitive language. This means that language keywords, variables,
function names, and any other identifiers must always be typed with a consistent capitalization
of letters.
$10.99
Get access to the full document:

100% satisfaction guarantee
Immediately available after payment
Both online and in PDF
No strings attached

Get to know the seller
Seller avatar
peterranadive

Get to know the seller

Seller avatar
peterranadive computer coding languages
Follow You need to be logged in order to follow users or courses
Sold
0
Member since
2 year
Number of followers
0
Documents
3
Last sold
-

0.0

0 reviews

5
0
4
0
3
0
2
0
1
0

Recently viewed by you

Why students choose Stuvia

Created by fellow students, verified by reviews

Quality you can trust: written by students who passed their tests and reviewed by others who've used these notes.

Didn't get what you expected? Choose another document

No worries! You can instantly pick a different document that better fits what you're looking for.

Pay as you like, start learning right away

No subscription, no commitments. Pay the way you're used to via credit card and download your PDF document instantly.

Student with book image

“Bought, downloaded, and aced it. It really can be that simple.”

Alisha Student

Frequently asked questions