SlideShare a Scribd company logo
JavaScript / Web Engineering / Web Development / html + css + js/presentation
Topic
JavaScript
Group Member:
• Hamza Khan
• Mohammad Sajid
• Abdul Wahab
What can we do with Java Script
•Make webpage interactive
•Slider
•Image Galleries
•Form Validation
•Game Development
Java Script tag
• <script type=“text/Java script”></script>
How To Generate Message
Alert(“Hello world”);
Document.write Function in javascript
written on web page
• Document.write();
Show on web page
Document.write(“Hello world”);
Document.write Function in javascript
• Heading on webpage by javaScript
Document.write(“<h1>Hello</h1>”)
Types in java Script
1-String
2-Number
3-Boolean
4-Array
5-Object
Variable in java Script
• Variable are used to hold or store data
How to take data type in java script
Var name=“Ali Bhai”;
Alert(name);
Alert(typeof name);
Variable in java Script(cont)
Var num=25;
Alert(num);
Alert(typeof num);
Var Hk=“null”;
Alert(Hk);
(typeof object);
If-else Statement in javaScript
Syntax:
If(Condition){
//execute if block
}
Else{
//execute else block
}
If-else Statement in javaScript(con)
Var a=10;
Var b=11;
If(a==b)
{
Alert(“values are equal”);
}
Else
{
Alert(“Values are not equal”);
}
Functions in javascript
• Function eliminates the need of writing the
same code again and again.
Function welcome(){
Alert(“welcome to College”);
}
Welcome();
Welcome();
Airthmetic operations in JavaScript
• Addition +
• Subtraction –
• Multiplication *
• Division /
• (Division Reminder)%
• Increment ++
• Decrement --
Addition program in javaScript
Var add = 10 + 15;
document.write(add);
Here,
Operand=10 and 15
Operator= + sign
Subtraction program in javaScript
Var sub = 10 - 5;
document.write(sub);
Here,
Operand=10 and 15
Operator= - sign
Multiplication program in
javaScript
Var mul = 5 * 5;
document.write(mul);
Here,
Operand=5 and 5
Operator= * sign
Division program in javaScript
Var div = 5/5;
document.write(div);
Here,
Operand=5 and 5
Operator= / sign
Remainder program in javaScript
Var rem = 5%5;
document.write(rem);
Here,
Operand=5 and 5
Operator= % sign
Operator order of Precedence in javaScript
Var rem = 5+5*10;
document.write(rem);
First precedence Multiplication and
Division
Answer=55
Operator order of Precedence in
javaScript(Cont)
Var rem = (5+5)*10;
document.write(rem);
First Highest precedence is bracket
then Multiplication and Division
Answer=100
Increment and decrement operator in
javascript
Var Ans=10;
Ans++;
document.write(Ans);
Var Ans=11;
Ans--;
document.write(Ans);
Comparison operator in javascript
• ==(equal to)
• ===(equal value and type)
• !=(not equal)
• > greater than
• < Less than
• >= (greater than or equal to)
• < =(Less than or equal to)
Comparison operator in javascript(cont)
Var a=10, b=10
If(a==b){
document.write(“both values are
same”);
}
Ans=both values are same
Comparison operator in javascript(cont)
Var a=10, b=“10”
If(a===b){
document.write(“both values are same”);
}
Else{
document.write(“both values not are
same”);
}
Ans=not same
// because triple equal check values and
data type also
Comparison operator in javascript(cont)
Var a=10, b=5
If(a!=b){
document.write(“both values are not equal”);
}
Comparison operator in javascript(cont)
Var a=10, b=5
If(a>b){
document.write(“a greater than b”);
}
Comparison operator in javascript(cont)
Var a=10, b=5
If(a<b){
document.write(“a Less than b”);
}
Comparison operator in javascript(cont)
Var age=18
If(age >=18)
{
document.write(“you are eligible”);
}
Else{
Alert(“not Eligible”);
}
Ans=eligible
Math funcitons in javaScript
• Math.round();
• Math.sqrt();
• Math.power();
• Math.min();
• Math.max();
• Math.random();
• Math.floor(math.random() * 1000);
Loop in JavaScript
• For Loop
• While Loop
• Do while Loop
For loop in JavaScript
Syntax;
for(initialization; condition; increment/decriment )
E.g:
For(var i=1; i<6; i++)
{ document.write( “hello” + I + “ <br/ >” )
}
While Loop in javaScript
E.g:
var i=1;
While( i < 6 )
{ document.write( “hello”+ I + “ <br/ >” )
i++;
}
Do While loop in javaScript
E.g:
Var i=1;
do
{ document.write{“hello”+i+”<br>”}
i++;
}
While(i<6);
Array
Arrays
Data structures of related items
Each element has a position number
Dynamic
Size of an array in JavaScript can be changed
(increased) AFTER it is created
Arrays in JavaScript
• Each element referenced by a number
Start at “zeroth element”: 10 element array
has elements: 0,1,2 ,..,8,9
Subscript or index
• Accessing a specific element
Name of array
Brackets
Number of element
• Arrays know their length
length property
c[ 6 ]
-45
6
0
72
1543
-89
0
62
-3
1
6453
78
Name of array c[ 0 ]
c[ 1 ]
c[ 2 ]
c[ 3 ]
c[ 11 ]
c[ 10 ]
c[ 9 ]
c[ 8 ]
c[ 7 ]
c[ 5 ]
c[ 4 ]
Position number (index
or subscript) of the
element within array c
Fig. 11.1 A 12-element array.
Declaring and Allocating Arrays
• Arrays in memory
– Objects
– Operator new
• Allocates memory for objects
• Dynamic memory allocation operator
var c;  array declaration
c = new Array( 12 );  memory allocation
Using Arrays
• Arrays can grow dynamically
– Allocate more space as more items are added
than originally planned for
• Array elements must be initialized explicitly
– Default value is “undefined”
– for loops convenient fro initialization
– Referring to uninitialized elements or elements
outside array bounds is an error
Examples Using Arrays
• for…in statement
– Perform an action for each element in an array
– Iterates over array elements
• Assigns each element to specified variable one at a
time
– Ignores non-existent elements
Multidimensional Arrays
• Two-dimensional arrays analogous to tables
– Rows and columns
• Specify row first, then column
– Two subscripts
Multidimensional Arrays
a[ 1 ][ 0 ] a[ 1 ][ 1 ] a[ 1 ][ 2 ] a[ 1 ][ 3 ]
Row 0
Row 1
Row 2
Column 0 Column 1 Column 2 Column 3
Row subscript (or index)
Array name
Column subscript (or index)
a[ 0 ][ 0 ] a[ 0 ][ 1 ] a[ 0 ][ 2 ] a[ 0 ][ 3 ]
a[ 2 ][ 0 ] a[ 2 ][ 1 ] a[ 2 ][ 2 ] a[ 2 ][ 3 ]
Two-dimensional array with three rows and four columns.
JavaScript / Web Engineering / Web Development / html + css + js/presentation

More Related Content

What's hot (20)

Stack and its Applications : Data Structures ADT
Stack and its Applications : Data Structures ADTStack and its Applications : Data Structures ADT
Stack and its Applications : Data Structures ADT
Soumen Santra
 
header, circular and two way linked lists
header, circular and two way linked listsheader, circular and two way linked lists
header, circular and two way linked lists
student
 
Collections in Java Notes
Collections in Java NotesCollections in Java Notes
Collections in Java Notes
Shalabh Chaudhary
 
NOSQL Databases types and Uses
NOSQL Databases types and UsesNOSQL Databases types and Uses
NOSQL Databases types and Uses
Suvradeep Rudra
 
MySQL 8.0.16 New Features Summary
MySQL 8.0.16 New Features SummaryMySQL 8.0.16 New Features Summary
MySQL 8.0.16 New Features Summary
Olivier DASINI
 
Threads concept in java
Threads concept in javaThreads concept in java
Threads concept in java
Muthukumaran Subramanian
 
JVM
JVMJVM
JVM
baabtra.com - No. 1 supplier of quality freshers
 
Integrity constraints in dbms
Integrity constraints in dbmsIntegrity constraints in dbms
Integrity constraints in dbms
Vignesh Saravanan
 
Thread model in java
Thread model in javaThread model in java
Thread model in java
AmbigaMurugesan
 
C# Asynchronous delegates
C# Asynchronous delegatesC# Asynchronous delegates
C# Asynchronous delegates
Prem Kumar Badri
 
Collections Api - Java
Collections Api - JavaCollections Api - Java
Collections Api - Java
Drishti Bhalla
 
Database Triggers
Database TriggersDatabase Triggers
Database Triggers
Aliya Saldanha
 
Chapter 11 - Sorting and Searching
Chapter 11 - Sorting and SearchingChapter 11 - Sorting and Searching
Chapter 11 - Sorting and Searching
Eduardo Bergavera
 
SQL Tutorial - Basic Commands
SQL Tutorial - Basic CommandsSQL Tutorial - Basic Commands
SQL Tutorial - Basic Commands
1keydata
 
Sql group functions
Sql group functionsSql group functions
Sql group functions
Sumit Tambe
 
Java layoutmanager
Java layoutmanagerJava layoutmanager
Java layoutmanager
Arati Gadgil
 
Data structure - Graph
Data structure - GraphData structure - Graph
Data structure - Graph
Madhu Bala
 
Java Threads
Java ThreadsJava Threads
Java Threads
M Vishnuvardhan Reddy
 
Packages in PL/SQL
Packages in PL/SQLPackages in PL/SQL
Packages in PL/SQL
Pooja Dixit
 
SQL Commands
SQL Commands SQL Commands
SQL Commands
Sachidananda M H
 

Similar to JavaScript / Web Engineering / Web Development / html + css + js/presentation (20)

Javascript 101
Javascript 101Javascript 101
Javascript 101
Shlomi Komemi
 
Introduction to Client-Side Javascript
Introduction to Client-Side JavascriptIntroduction to Client-Side Javascript
Introduction to Client-Side Javascript
Julie Iskander
 
CSC PPT 13.pptx
CSC PPT 13.pptxCSC PPT 13.pptx
CSC PPT 13.pptx
DrRavneetSingh
 
Java Script Basic to Advanced For Beginner to Advanced Learner.pptx
Java Script Basic to Advanced For Beginner to Advanced Learner.pptxJava Script Basic to Advanced For Beginner to Advanced Learner.pptx
Java Script Basic to Advanced For Beginner to Advanced Learner.pptx
sanjaydhumal26
 
Client sidescripting javascript
Client sidescripting javascriptClient sidescripting javascript
Client sidescripting javascript
Selvin Josy Bai Somu
 
Javascript
JavascriptJavascript
Javascript
Manav Prasad
 
Java script questions
Java script questionsJava script questions
Java script questions
Srikanth
 
Introduction to javascript.ppt
Introduction to javascript.pptIntroduction to javascript.ppt
Introduction to javascript.ppt
BArulmozhi
 
Fewd week5 slides
Fewd week5 slidesFewd week5 slides
Fewd week5 slides
William Myers
 
Javascript variables and datatypes
Javascript variables and datatypesJavascript variables and datatypes
Javascript variables and datatypes
Varun C M
 
Unit - 4 all script are here Javascript.pptx
Unit - 4 all script are here Javascript.pptxUnit - 4 all script are here Javascript.pptx
Unit - 4 all script are here Javascript.pptx
kushwahanitesh592
 
Web designing unit 4
Web designing unit 4Web designing unit 4
Web designing unit 4
Dr. SURBHI SAROHA
 
03. Week 03.pptx
03. Week 03.pptx03. Week 03.pptx
03. Week 03.pptx
Vinc2ntCabrera
 
Javascript - Tutorial
Javascript - TutorialJavascript - Tutorial
Javascript - Tutorial
adelaticleanu
 
An introduction to javascript
An introduction to javascriptAn introduction to javascript
An introduction to javascript
MD Sayem Ahmed
 
javascript-variablesanddatatypes-130218094831-phpapp01.pdf
javascript-variablesanddatatypes-130218094831-phpapp01.pdfjavascript-variablesanddatatypes-130218094831-phpapp01.pdf
javascript-variablesanddatatypes-130218094831-phpapp01.pdf
AlexShon3
 
1-JAVA SCRIPT. servere-side applications vs client side applications
1-JAVA SCRIPT. servere-side applications vs client side applications1-JAVA SCRIPT. servere-side applications vs client side applications
1-JAVA SCRIPT. servere-side applications vs client side applications
surajshreyans
 
JavaScript Proven Practises
JavaScript Proven PractisesJavaScript Proven Practises
JavaScript Proven Practises
Robert MacLean
 
GeoGebra JavaScript CheatSheet
GeoGebra JavaScript CheatSheetGeoGebra JavaScript CheatSheet
GeoGebra JavaScript CheatSheet
Jose Perez
 
An introduction to javascript
An introduction to javascriptAn introduction to javascript
An introduction to javascript
tonyh1
 
Introduction to Client-Side Javascript
Introduction to Client-Side JavascriptIntroduction to Client-Side Javascript
Introduction to Client-Side Javascript
Julie Iskander
 
Java Script Basic to Advanced For Beginner to Advanced Learner.pptx
Java Script Basic to Advanced For Beginner to Advanced Learner.pptxJava Script Basic to Advanced For Beginner to Advanced Learner.pptx
Java Script Basic to Advanced For Beginner to Advanced Learner.pptx
sanjaydhumal26
 
Java script questions
Java script questionsJava script questions
Java script questions
Srikanth
 
Introduction to javascript.ppt
Introduction to javascript.pptIntroduction to javascript.ppt
Introduction to javascript.ppt
BArulmozhi
 
Javascript variables and datatypes
Javascript variables and datatypesJavascript variables and datatypes
Javascript variables and datatypes
Varun C M
 
Unit - 4 all script are here Javascript.pptx
Unit - 4 all script are here Javascript.pptxUnit - 4 all script are here Javascript.pptx
Unit - 4 all script are here Javascript.pptx
kushwahanitesh592
 
Javascript - Tutorial
Javascript - TutorialJavascript - Tutorial
Javascript - Tutorial
adelaticleanu
 
An introduction to javascript
An introduction to javascriptAn introduction to javascript
An introduction to javascript
MD Sayem Ahmed
 
javascript-variablesanddatatypes-130218094831-phpapp01.pdf
javascript-variablesanddatatypes-130218094831-phpapp01.pdfjavascript-variablesanddatatypes-130218094831-phpapp01.pdf
javascript-variablesanddatatypes-130218094831-phpapp01.pdf
AlexShon3
 
1-JAVA SCRIPT. servere-side applications vs client side applications
1-JAVA SCRIPT. servere-side applications vs client side applications1-JAVA SCRIPT. servere-side applications vs client side applications
1-JAVA SCRIPT. servere-side applications vs client side applications
surajshreyans
 
JavaScript Proven Practises
JavaScript Proven PractisesJavaScript Proven Practises
JavaScript Proven Practises
Robert MacLean
 
GeoGebra JavaScript CheatSheet
GeoGebra JavaScript CheatSheetGeoGebra JavaScript CheatSheet
GeoGebra JavaScript CheatSheet
Jose Perez
 
An introduction to javascript
An introduction to javascriptAn introduction to javascript
An introduction to javascript
tonyh1
 
Ad

More from M Sajid R (6)

Binary Search Tree (BST)
Binary Search Tree (BST)Binary Search Tree (BST)
Binary Search Tree (BST)
M Sajid R
 
Transport layer
Transport layerTransport layer
Transport layer
M Sajid R
 
Novartis
NovartisNovartis
Novartis
M Sajid R
 
Query o
Query oQuery o
Query o
M Sajid R
 
Network And Topology
Network And Topology Network And Topology
Network And Topology
M Sajid R
 
Toyota
ToyotaToyota
Toyota
M Sajid R
 
Binary Search Tree (BST)
Binary Search Tree (BST)Binary Search Tree (BST)
Binary Search Tree (BST)
M Sajid R
 
Transport layer
Transport layerTransport layer
Transport layer
M Sajid R
 
Network And Topology
Network And Topology Network And Topology
Network And Topology
M Sajid R
 
Ad

Recently uploaded (20)

THERAPEUTIC COMMUNICATION included definition, characteristics, nurse patient...
THERAPEUTIC COMMUNICATION included definition, characteristics, nurse patient...THERAPEUTIC COMMUNICATION included definition, characteristics, nurse patient...
THERAPEUTIC COMMUNICATION included definition, characteristics, nurse patient...
parmarjuli1412
 
Basic English for Communication - Dr Hj Euis Eti Rohaeti Mpd
Basic English for Communication - Dr Hj Euis Eti Rohaeti MpdBasic English for Communication - Dr Hj Euis Eti Rohaeti Mpd
Basic English for Communication - Dr Hj Euis Eti Rohaeti Mpd
Restu Bias Primandhika
 
LDMMIA Reiki Yoga Next Week Grad Updates
LDMMIA Reiki Yoga Next Week Grad UpdatesLDMMIA Reiki Yoga Next Week Grad Updates
LDMMIA Reiki Yoga Next Week Grad Updates
LDM & Mia eStudios
 
Different pricelists for different shops in odoo Point of Sale in Odoo 17
Different pricelists for different shops in odoo Point of Sale in Odoo 17Different pricelists for different shops in odoo Point of Sale in Odoo 17
Different pricelists for different shops in odoo Point of Sale in Odoo 17
Celine George
 
Artificial intelligence Presented by JM.
Artificial intelligence Presented by JM.Artificial intelligence Presented by JM.
Artificial intelligence Presented by JM.
jmansha170
 
How to Manage Maintenance Request in Odoo 18
How to Manage Maintenance Request in Odoo 18How to Manage Maintenance Request in Odoo 18
How to Manage Maintenance Request in Odoo 18
Celine George
 
Unit 3 Poster Sketches with annotations.pptx
Unit 3 Poster Sketches with annotations.pptxUnit 3 Poster Sketches with annotations.pptx
Unit 3 Poster Sketches with annotations.pptx
bobby205207
 
Module 4 Presentation - Enhancing Competencies and Engagement Strategies in Y...
Module 4 Presentation - Enhancing Competencies and Engagement Strategies in Y...Module 4 Presentation - Enhancing Competencies and Engagement Strategies in Y...
Module 4 Presentation - Enhancing Competencies and Engagement Strategies in Y...
GeorgeDiamandis11
 
Ray Dalio How Countries go Broke the Big Cycle
Ray Dalio How Countries go Broke the Big CycleRay Dalio How Countries go Broke the Big Cycle
Ray Dalio How Countries go Broke the Big Cycle
Dadang Solihin
 
Unit- 4 Biostatistics & Research Methodology.pdf
Unit- 4 Biostatistics & Research Methodology.pdfUnit- 4 Biostatistics & Research Methodology.pdf
Unit- 4 Biostatistics & Research Methodology.pdf
KRUTIKA CHANNE
 
Rai dyansty Chach or Brahamn dynasty, History of Dahir History of Sindh NEP.pptx
Rai dyansty Chach or Brahamn dynasty, History of Dahir History of Sindh NEP.pptxRai dyansty Chach or Brahamn dynasty, History of Dahir History of Sindh NEP.pptx
Rai dyansty Chach or Brahamn dynasty, History of Dahir History of Sindh NEP.pptx
Dr. Ravi Shankar Arya Mahila P. G. College, Banaras Hindu University, Varanasi, India.
 
Final Sketch Designs for poster production.pptx
Final Sketch Designs for poster production.pptxFinal Sketch Designs for poster production.pptx
Final Sketch Designs for poster production.pptx
bobby205207
 
How to Create a Rainbow Man Effect in Odoo 18
How to Create a Rainbow Man Effect in Odoo 18How to Create a Rainbow Man Effect in Odoo 18
How to Create a Rainbow Man Effect in Odoo 18
Celine George
 
Parenting Teens: Supporting Trust, resilience and independence
Parenting Teens: Supporting Trust, resilience and independenceParenting Teens: Supporting Trust, resilience and independence
Parenting Teens: Supporting Trust, resilience and independence
Pooky Knightsmith
 
How to Configure Vendor Management in Lunch App of Odoo 18
How to Configure Vendor Management in Lunch App of Odoo 18How to Configure Vendor Management in Lunch App of Odoo 18
How to Configure Vendor Management in Lunch App of Odoo 18
Celine George
 
FEBA Sofia Univercity final diplian v3 GSDG 5.2025.pdf
FEBA Sofia Univercity final diplian v3 GSDG 5.2025.pdfFEBA Sofia Univercity final diplian v3 GSDG 5.2025.pdf
FEBA Sofia Univercity final diplian v3 GSDG 5.2025.pdf
ChristinaFortunova
 
Hemiptera & Neuroptera: Insect Diversity.pptx
Hemiptera & Neuroptera: Insect Diversity.pptxHemiptera & Neuroptera: Insect Diversity.pptx
Hemiptera & Neuroptera: Insect Diversity.pptx
Arshad Shaikh
 
LDMMIA Free Reiki Yoga S9 Grad Level Intuition II
LDMMIA Free Reiki Yoga S9 Grad Level Intuition IILDMMIA Free Reiki Yoga S9 Grad Level Intuition II
LDMMIA Free Reiki Yoga S9 Grad Level Intuition II
LDM & Mia eStudios
 
Webcrawler_Mule_AIChain_MuleSoft_Meetup_Hyderabad
Webcrawler_Mule_AIChain_MuleSoft_Meetup_HyderabadWebcrawler_Mule_AIChain_MuleSoft_Meetup_Hyderabad
Webcrawler_Mule_AIChain_MuleSoft_Meetup_Hyderabad
Veera Pallapu
 
Strengthened Senior High School - Landas Tool Kit.pptx
Strengthened Senior High School - Landas Tool Kit.pptxStrengthened Senior High School - Landas Tool Kit.pptx
Strengthened Senior High School - Landas Tool Kit.pptx
SteffMusniQuiballo
 
THERAPEUTIC COMMUNICATION included definition, characteristics, nurse patient...
THERAPEUTIC COMMUNICATION included definition, characteristics, nurse patient...THERAPEUTIC COMMUNICATION included definition, characteristics, nurse patient...
THERAPEUTIC COMMUNICATION included definition, characteristics, nurse patient...
parmarjuli1412
 
Basic English for Communication - Dr Hj Euis Eti Rohaeti Mpd
Basic English for Communication - Dr Hj Euis Eti Rohaeti MpdBasic English for Communication - Dr Hj Euis Eti Rohaeti Mpd
Basic English for Communication - Dr Hj Euis Eti Rohaeti Mpd
Restu Bias Primandhika
 
LDMMIA Reiki Yoga Next Week Grad Updates
LDMMIA Reiki Yoga Next Week Grad UpdatesLDMMIA Reiki Yoga Next Week Grad Updates
LDMMIA Reiki Yoga Next Week Grad Updates
LDM & Mia eStudios
 
Different pricelists for different shops in odoo Point of Sale in Odoo 17
Different pricelists for different shops in odoo Point of Sale in Odoo 17Different pricelists for different shops in odoo Point of Sale in Odoo 17
Different pricelists for different shops in odoo Point of Sale in Odoo 17
Celine George
 
Artificial intelligence Presented by JM.
Artificial intelligence Presented by JM.Artificial intelligence Presented by JM.
Artificial intelligence Presented by JM.
jmansha170
 
How to Manage Maintenance Request in Odoo 18
How to Manage Maintenance Request in Odoo 18How to Manage Maintenance Request in Odoo 18
How to Manage Maintenance Request in Odoo 18
Celine George
 
Unit 3 Poster Sketches with annotations.pptx
Unit 3 Poster Sketches with annotations.pptxUnit 3 Poster Sketches with annotations.pptx
Unit 3 Poster Sketches with annotations.pptx
bobby205207
 
Module 4 Presentation - Enhancing Competencies and Engagement Strategies in Y...
Module 4 Presentation - Enhancing Competencies and Engagement Strategies in Y...Module 4 Presentation - Enhancing Competencies and Engagement Strategies in Y...
Module 4 Presentation - Enhancing Competencies and Engagement Strategies in Y...
GeorgeDiamandis11
 
Ray Dalio How Countries go Broke the Big Cycle
Ray Dalio How Countries go Broke the Big CycleRay Dalio How Countries go Broke the Big Cycle
Ray Dalio How Countries go Broke the Big Cycle
Dadang Solihin
 
Unit- 4 Biostatistics & Research Methodology.pdf
Unit- 4 Biostatistics & Research Methodology.pdfUnit- 4 Biostatistics & Research Methodology.pdf
Unit- 4 Biostatistics & Research Methodology.pdf
KRUTIKA CHANNE
 
Final Sketch Designs for poster production.pptx
Final Sketch Designs for poster production.pptxFinal Sketch Designs for poster production.pptx
Final Sketch Designs for poster production.pptx
bobby205207
 
How to Create a Rainbow Man Effect in Odoo 18
How to Create a Rainbow Man Effect in Odoo 18How to Create a Rainbow Man Effect in Odoo 18
How to Create a Rainbow Man Effect in Odoo 18
Celine George
 
Parenting Teens: Supporting Trust, resilience and independence
Parenting Teens: Supporting Trust, resilience and independenceParenting Teens: Supporting Trust, resilience and independence
Parenting Teens: Supporting Trust, resilience and independence
Pooky Knightsmith
 
How to Configure Vendor Management in Lunch App of Odoo 18
How to Configure Vendor Management in Lunch App of Odoo 18How to Configure Vendor Management in Lunch App of Odoo 18
How to Configure Vendor Management in Lunch App of Odoo 18
Celine George
 
FEBA Sofia Univercity final diplian v3 GSDG 5.2025.pdf
FEBA Sofia Univercity final diplian v3 GSDG 5.2025.pdfFEBA Sofia Univercity final diplian v3 GSDG 5.2025.pdf
FEBA Sofia Univercity final diplian v3 GSDG 5.2025.pdf
ChristinaFortunova
 
Hemiptera & Neuroptera: Insect Diversity.pptx
Hemiptera & Neuroptera: Insect Diversity.pptxHemiptera & Neuroptera: Insect Diversity.pptx
Hemiptera & Neuroptera: Insect Diversity.pptx
Arshad Shaikh
 
LDMMIA Free Reiki Yoga S9 Grad Level Intuition II
LDMMIA Free Reiki Yoga S9 Grad Level Intuition IILDMMIA Free Reiki Yoga S9 Grad Level Intuition II
LDMMIA Free Reiki Yoga S9 Grad Level Intuition II
LDM & Mia eStudios
 
Webcrawler_Mule_AIChain_MuleSoft_Meetup_Hyderabad
Webcrawler_Mule_AIChain_MuleSoft_Meetup_HyderabadWebcrawler_Mule_AIChain_MuleSoft_Meetup_Hyderabad
Webcrawler_Mule_AIChain_MuleSoft_Meetup_Hyderabad
Veera Pallapu
 
Strengthened Senior High School - Landas Tool Kit.pptx
Strengthened Senior High School - Landas Tool Kit.pptxStrengthened Senior High School - Landas Tool Kit.pptx
Strengthened Senior High School - Landas Tool Kit.pptx
SteffMusniQuiballo
 

JavaScript / Web Engineering / Web Development / html + css + js/presentation

  • 2. Topic JavaScript Group Member: • Hamza Khan • Mohammad Sajid • Abdul Wahab
  • 3. What can we do with Java Script •Make webpage interactive •Slider •Image Galleries •Form Validation •Game Development
  • 4. Java Script tag • <script type=“text/Java script”></script>
  • 5. How To Generate Message Alert(“Hello world”);
  • 6. Document.write Function in javascript written on web page • Document.write(); Show on web page Document.write(“Hello world”);
  • 7. Document.write Function in javascript • Heading on webpage by javaScript Document.write(“<h1>Hello</h1>”)
  • 8. Types in java Script 1-String 2-Number 3-Boolean 4-Array 5-Object
  • 9. Variable in java Script • Variable are used to hold or store data How to take data type in java script Var name=“Ali Bhai”; Alert(name); Alert(typeof name);
  • 10. Variable in java Script(cont) Var num=25; Alert(num); Alert(typeof num); Var Hk=“null”; Alert(Hk); (typeof object);
  • 11. If-else Statement in javaScript Syntax: If(Condition){ //execute if block } Else{ //execute else block }
  • 12. If-else Statement in javaScript(con) Var a=10; Var b=11; If(a==b) { Alert(“values are equal”); } Else { Alert(“Values are not equal”); }
  • 13. Functions in javascript • Function eliminates the need of writing the same code again and again. Function welcome(){ Alert(“welcome to College”); } Welcome(); Welcome();
  • 14. Airthmetic operations in JavaScript • Addition + • Subtraction – • Multiplication * • Division / • (Division Reminder)% • Increment ++ • Decrement --
  • 15. Addition program in javaScript Var add = 10 + 15; document.write(add); Here, Operand=10 and 15 Operator= + sign
  • 16. Subtraction program in javaScript Var sub = 10 - 5; document.write(sub); Here, Operand=10 and 15 Operator= - sign
  • 17. Multiplication program in javaScript Var mul = 5 * 5; document.write(mul); Here, Operand=5 and 5 Operator= * sign
  • 18. Division program in javaScript Var div = 5/5; document.write(div); Here, Operand=5 and 5 Operator= / sign
  • 19. Remainder program in javaScript Var rem = 5%5; document.write(rem); Here, Operand=5 and 5 Operator= % sign
  • 20. Operator order of Precedence in javaScript Var rem = 5+5*10; document.write(rem); First precedence Multiplication and Division Answer=55
  • 21. Operator order of Precedence in javaScript(Cont) Var rem = (5+5)*10; document.write(rem); First Highest precedence is bracket then Multiplication and Division Answer=100
  • 22. Increment and decrement operator in javascript Var Ans=10; Ans++; document.write(Ans); Var Ans=11; Ans--; document.write(Ans);
  • 23. Comparison operator in javascript • ==(equal to) • ===(equal value and type) • !=(not equal) • > greater than • < Less than • >= (greater than or equal to) • < =(Less than or equal to)
  • 24. Comparison operator in javascript(cont) Var a=10, b=10 If(a==b){ document.write(“both values are same”); } Ans=both values are same
  • 25. Comparison operator in javascript(cont) Var a=10, b=“10” If(a===b){ document.write(“both values are same”); } Else{ document.write(“both values not are same”); } Ans=not same // because triple equal check values and data type also
  • 26. Comparison operator in javascript(cont) Var a=10, b=5 If(a!=b){ document.write(“both values are not equal”); }
  • 27. Comparison operator in javascript(cont) Var a=10, b=5 If(a>b){ document.write(“a greater than b”); }
  • 28. Comparison operator in javascript(cont) Var a=10, b=5 If(a<b){ document.write(“a Less than b”); }
  • 29. Comparison operator in javascript(cont) Var age=18 If(age >=18) { document.write(“you are eligible”); } Else{ Alert(“not Eligible”); } Ans=eligible
  • 30. Math funcitons in javaScript • Math.round(); • Math.sqrt(); • Math.power(); • Math.min(); • Math.max(); • Math.random(); • Math.floor(math.random() * 1000);
  • 31. Loop in JavaScript • For Loop • While Loop • Do while Loop
  • 32. For loop in JavaScript Syntax; for(initialization; condition; increment/decriment ) E.g: For(var i=1; i<6; i++) { document.write( “hello” + I + “ <br/ >” ) }
  • 33. While Loop in javaScript E.g: var i=1; While( i < 6 ) { document.write( “hello”+ I + “ <br/ >” ) i++; }
  • 34. Do While loop in javaScript E.g: Var i=1; do { document.write{“hello”+i+”<br>”} i++; } While(i<6);
  • 35. Array Arrays Data structures of related items Each element has a position number Dynamic Size of an array in JavaScript can be changed (increased) AFTER it is created
  • 36. Arrays in JavaScript • Each element referenced by a number Start at “zeroth element”: 10 element array has elements: 0,1,2 ,..,8,9 Subscript or index • Accessing a specific element Name of array Brackets Number of element • Arrays know their length length property
  • 37. c[ 6 ] -45 6 0 72 1543 -89 0 62 -3 1 6453 78 Name of array c[ 0 ] c[ 1 ] c[ 2 ] c[ 3 ] c[ 11 ] c[ 10 ] c[ 9 ] c[ 8 ] c[ 7 ] c[ 5 ] c[ 4 ] Position number (index or subscript) of the element within array c Fig. 11.1 A 12-element array.
  • 38. Declaring and Allocating Arrays • Arrays in memory – Objects – Operator new • Allocates memory for objects • Dynamic memory allocation operator var c;  array declaration c = new Array( 12 );  memory allocation
  • 39. Using Arrays • Arrays can grow dynamically – Allocate more space as more items are added than originally planned for • Array elements must be initialized explicitly – Default value is “undefined” – for loops convenient fro initialization – Referring to uninitialized elements or elements outside array bounds is an error
  • 40. Examples Using Arrays • for…in statement – Perform an action for each element in an array – Iterates over array elements • Assigns each element to specified variable one at a time – Ignores non-existent elements
  • 41. Multidimensional Arrays • Two-dimensional arrays analogous to tables – Rows and columns • Specify row first, then column – Two subscripts
  • 42. Multidimensional Arrays a[ 1 ][ 0 ] a[ 1 ][ 1 ] a[ 1 ][ 2 ] a[ 1 ][ 3 ] Row 0 Row 1 Row 2 Column 0 Column 1 Column 2 Column 3 Row subscript (or index) Array name Column subscript (or index) a[ 0 ][ 0 ] a[ 0 ][ 1 ] a[ 0 ][ 2 ] a[ 0 ][ 3 ] a[ 2 ][ 0 ] a[ 2 ][ 1 ] a[ 2 ][ 2 ] a[ 2 ][ 3 ] Two-dimensional array with three rows and four columns.