SlideShare a Scribd company logo
1 of 2
Download to read offline
Web Authoring                                                                                  Name:
Lesson Completion Sheet

W3School JavaScript
JavaScript Comments, Variables, If…Else, Switch, Operators

For this lesson, you will be going through the JavaScript Comments tutorial on the W3Schools web site located at
www.w3schools.com/js/js_comments.asp, then the JavaScript Variables tutorial on the W3Schools web site located
at www.w3schools.com/js/js_variables.asp, then the JavaScript If…Else tutorial on the W3Schools web site located at
www.w3schools.com/js/js_if_else.asp, then the JavaScript Switch tutorial on the W3Schools web site located at
www.w3schools.com/js/js_statements.asp, then the JavaScript Operators tutorial on the W3Schools web site
located at www.w3schools.com/js/js_operators.asp .

All files that you save as part of this lesson should be saved in a folder called JavaScript Comments inside a folder called
w3school javascript that you create in your network folder for this course.

Assignments                                                                                                  X    X     Grade
Read through the JavaScript Comments tutorial.
Use notepad to create an HTML document. Include a JavaScript section made up of document.write                              /10
statements that would create this: (use one document.write statement for each line)
<h1>Athletics</h1>
<h2>Boys</h2>
<ul>
<li>Basketball</li>
<li>Soccer</li>
<li>Track</li>
</ul>
<h2>Girls</h2>
<ul>
<li>Basketball</li>
<li>Soccer</li>
<li>Volleyball</li>
</ul>

- Add this multi-line comment at the beginning of the script:
This script shows a list of
boys and girls athletic offerings
- Add a single line comment This is the list of boys sports between the Boys header and the beginning of
the list.
- Prevent the list item Track from being displayed by commenting it
- Prevent the entire list under the Girls heading from being displayed by using a multiline comment
- Add an end of line comment aka Sports to the Athletic header line
Save your HTML document as comment1.htm
Read through the JavaScript Variables tutorial.
Look at the Variable example. Use notepad to create an HTML document that contains JavaScript code                          /10
that will save five different words as five different variables, then display those five words. Save your
document as variable1.htm.
Read through the JavaScript If..Else tutorial.
Look at the If statement example. Use notepad to create an HTML document. Copy the HTML from                                /10
the example into your HTML document. Get rid of the stuff in the p tags. Add to the script so that the
greeting “Lunch time!” if the hour value of the time is 12 (12:00-12:59pm) and “Good afternoon” if the
time is greater than 12 (1pm or later). Save your document as if1.htm.
I:My Documentsweb authoringassignmentsw3schools javascript basicw3schools javascript comments.docx               Page 1 of 2
Look at the If…else statement example. Use notepad to create an HTML document. Copy the HTML                           /10
from the example into your HTML document. Get rid of the stuff in the p tags. Change getHours in the
script to getDay, this will give the day of the week, numbered 0-6 (Sunday=0, Monday=1, etc). Change
the script so that on Fridays (day 5), it will display “Thank goodness its Friday!” and so that it will
display “It’s not Friday yet.” On all other days. Save your document as if2.htm.
Look at the If…else if…else statement example. Use notepad to create an HTML document. Copy the                        /10
HTML from the example into your HTML document. Get rid of the stuff in the p tags. Change getHours
in the script to getMonth, this will give the month of the year, numbered 0-11. Change the script so
that in January – May it will display “I can’t wait for summer”; during June, July and August, it will
display “I love the summer!” and in September – December it will display “I can’t wait for summer”
again. Save your document as if3.htm.
Look at the Random link example. Use notepad to create an HTML document. Make an h1 header                             /10
that says “Coin Toss”. Include a JavaScript script that displays a picture of heads or a picture of
tails.based on the random number generate in the script. Save your document as if4.htm ;
Read through the JavaScript Switch tutorial.
Look at the Switch Statement example. Use notepad to creat an HTML document. Write a JavaScript                        /10
script that uses the getMonth command to get the current month number (0-11) then displays the
actual month name. Save your document as switch1.htm
Read through the JavaScript Operators example.
Use notepad to create an HTML document. Think of a sentence that is five words long. Write a                           /10
JavaScript script that stores each of these words in a variable then writes the whole sentence by
“adding” these five variables together. Save your document as operator1.htm.
                                                                                                                       /80

When you have completed the assignments for this lesson, staple any printouts to the back of this sheet in order and
hand it in to the teacher.




I:My Documentsweb authoringassignmentsw3schools javascript basicw3schools javascript comments.docx       Page 2 of 2

More Related Content

Viewers also liked

Case Study: Sprint Simplifies IT Environment with Speedy Implementation of To...
Case Study: Sprint Simplifies IT Environment with Speedy Implementation of To...Case Study: Sprint Simplifies IT Environment with Speedy Implementation of To...
Case Study: Sprint Simplifies IT Environment with Speedy Implementation of To...Dana Gardner
 
cascadingstylesheets
cascadingstylesheetscascadingstylesheets
cascadingstylesheetstutorialsruby
 
Web Design Unit.doc
Web Design Unit.docWeb Design Unit.doc
Web Design Unit.docbutest
 
Iisec dt-2011-10
Iisec dt-2011-10Iisec dt-2011-10
Iisec dt-2011-10PaolaReyesR
 
Class 1: Welcome to programming
Class 1: Welcome to programmingClass 1: Welcome to programming
Class 1: Welcome to programmingMarc Gouw
 
Informanten Efterår 06
Informanten Efterår 06Informanten Efterår 06
Informanten Efterår 06Jonas Sindal
 
Standardization and Knowledge Transfer – INS0
Standardization and Knowledge Transfer – INS0Standardization and Knowledge Transfer – INS0
Standardization and Knowledge Transfer – INS0tutorialsruby
 
Aconcagua 2010
Aconcagua 2010Aconcagua 2010
Aconcagua 2010NFS
 
How To Use Linked In To Grow Your Business
How To Use Linked In To Grow Your BusinessHow To Use Linked In To Grow Your Business
How To Use Linked In To Grow Your Businessgalbrecht
 
Classes and objects till 16 aug
Classes and objects till 16 augClasses and objects till 16 aug
Classes and objects till 16 augshashank12march
 
Loops Basics
Loops BasicsLoops Basics
Loops BasicsMushiii
 
Intro to C++ Basic
Intro to C++ BasicIntro to C++ Basic
Intro to C++ BasicShih Chi Lin
 
c++ programming Unit 2 basic structure of a c++ program
c++ programming Unit 2 basic structure of a c++ programc++ programming Unit 2 basic structure of a c++ program
c++ programming Unit 2 basic structure of a c++ programAAKASH KUMAR
 
Basic structure of C++ program
Basic structure of C++ programBasic structure of C++ program
Basic structure of C++ programmatiur rahman
 

Viewers also liked (20)

Case Study: Sprint Simplifies IT Environment with Speedy Implementation of To...
Case Study: Sprint Simplifies IT Environment with Speedy Implementation of To...Case Study: Sprint Simplifies IT Environment with Speedy Implementation of To...
Case Study: Sprint Simplifies IT Environment with Speedy Implementation of To...
 
cascadingstylesheets
cascadingstylesheetscascadingstylesheets
cascadingstylesheets
 
Web Design Unit.doc
Web Design Unit.docWeb Design Unit.doc
Web Design Unit.doc
 
Iisec dt-2011-10
Iisec dt-2011-10Iisec dt-2011-10
Iisec dt-2011-10
 
Class 1: Welcome to programming
Class 1: Welcome to programmingClass 1: Welcome to programming
Class 1: Welcome to programming
 
Lab 1
Lab 1Lab 1
Lab 1
 
Informanten Efterår 06
Informanten Efterår 06Informanten Efterår 06
Informanten Efterår 06
 
Basic of c &c++
Basic of c &c++Basic of c &c++
Basic of c &c++
 
Lect35 javascript
Lect35 javascriptLect35 javascript
Lect35 javascript
 
Standardization and Knowledge Transfer – INS0
Standardization and Knowledge Transfer – INS0Standardization and Knowledge Transfer – INS0
Standardization and Knowledge Transfer – INS0
 
Aconcagua 2010
Aconcagua 2010Aconcagua 2010
Aconcagua 2010
 
01 basic programming in c++
01 basic programming in c++01 basic programming in c++
01 basic programming in c++
 
How To Use Linked In To Grow Your Business
How To Use Linked In To Grow Your BusinessHow To Use Linked In To Grow Your Business
How To Use Linked In To Grow Your Business
 
Classes and objects till 16 aug
Classes and objects till 16 augClasses and objects till 16 aug
Classes and objects till 16 aug
 
Loops Basics
Loops BasicsLoops Basics
Loops Basics
 
Intro to C++ Basic
Intro to C++ BasicIntro to C++ Basic
Intro to C++ Basic
 
Loops c++
Loops c++Loops c++
Loops c++
 
Basic concept of c++
Basic concept of c++Basic concept of c++
Basic concept of c++
 
c++ programming Unit 2 basic structure of a c++ program
c++ programming Unit 2 basic structure of a c++ programc++ programming Unit 2 basic structure of a c++ program
c++ programming Unit 2 basic structure of a c++ program
 
Basic structure of C++ program
Basic structure of C++ programBasic structure of C++ program
Basic structure of C++ program
 

Similar to w3schools%20javascript%20comments

Introduction to java script
Introduction to java scriptIntroduction to java script
Introduction to java scriptnanjil1984
 
php-mysql-tutorial-part-3
php-mysql-tutorial-part-3php-mysql-tutorial-part-3
php-mysql-tutorial-part-3tutorialsruby
 
&lt;b>PHP&lt;/b>/MySQL &lt;b>Tutorial&lt;/b> webmonkey/programming/
&lt;b>PHP&lt;/b>/MySQL &lt;b>Tutorial&lt;/b> webmonkey/programming/&lt;b>PHP&lt;/b>/MySQL &lt;b>Tutorial&lt;/b> webmonkey/programming/
&lt;b>PHP&lt;/b>/MySQL &lt;b>Tutorial&lt;/b> webmonkey/programming/tutorialsruby
 
php-mysql-tutorial-part-3
php-mysql-tutorial-part-3php-mysql-tutorial-part-3
php-mysql-tutorial-part-3tutorialsruby
 
&lt;img src="../i/r_14.png" />
&lt;img src="../i/r_14.png" />&lt;img src="../i/r_14.png" />
&lt;img src="../i/r_14.png" />tutorialsruby
 
Vb script tutorial for qtp[1]
Vb script tutorial for qtp[1]Vb script tutorial for qtp[1]
Vb script tutorial for qtp[1]srikanthbkm
 
CHAPTER 3 JS (1).pptx
CHAPTER 3  JS (1).pptxCHAPTER 3  JS (1).pptx
CHAPTER 3 JS (1).pptxachutachut
 
JavaScript - Getting Started.pptx
JavaScript - Getting Started.pptxJavaScript - Getting Started.pptx
JavaScript - Getting Started.pptxJonnJorellPunto
 
Javascript survival for CSBN Sophomores
Javascript survival for CSBN SophomoresJavascript survival for CSBN Sophomores
Javascript survival for CSBN SophomoresAndy de Vera
 
First Pages HTML ASP-ASP.NET
First Pages HTML ASP-ASP.NETFirst Pages HTML ASP-ASP.NET
First Pages HTML ASP-ASP.NETsunmitraeducation
 
Basic JavaScript Tutorial
Basic JavaScript TutorialBasic JavaScript Tutorial
Basic JavaScript TutorialDHTMLExtreme
 
Placement and variable 03 (js)
Placement and variable 03 (js)Placement and variable 03 (js)
Placement and variable 03 (js)AbhishekMondal42
 

Similar to w3schools%20javascript%20comments (20)

Unit 2.4
Unit 2.4Unit 2.4
Unit 2.4
 
Unit 2.4
Unit 2.4Unit 2.4
Unit 2.4
 
Introduction to java script
Introduction to java scriptIntroduction to java script
Introduction to java script
 
Introduction to Java Scripting
Introduction to Java ScriptingIntroduction to Java Scripting
Introduction to Java Scripting
 
Web programming
Web programmingWeb programming
Web programming
 
php-mysql-tutorial-part-3
php-mysql-tutorial-part-3php-mysql-tutorial-part-3
php-mysql-tutorial-part-3
 
&lt;b>PHP&lt;/b>/MySQL &lt;b>Tutorial&lt;/b> webmonkey/programming/
&lt;b>PHP&lt;/b>/MySQL &lt;b>Tutorial&lt;/b> webmonkey/programming/&lt;b>PHP&lt;/b>/MySQL &lt;b>Tutorial&lt;/b> webmonkey/programming/
&lt;b>PHP&lt;/b>/MySQL &lt;b>Tutorial&lt;/b> webmonkey/programming/
 
php-mysql-tutorial-part-3
php-mysql-tutorial-part-3php-mysql-tutorial-part-3
php-mysql-tutorial-part-3
 
&lt;img src="../i/r_14.png" />
&lt;img src="../i/r_14.png" />&lt;img src="../i/r_14.png" />
&lt;img src="../i/r_14.png" />
 
JAVA SCRIPT
JAVA SCRIPTJAVA SCRIPT
JAVA SCRIPT
 
Vb script tutorial for qtp[1]
Vb script tutorial for qtp[1]Vb script tutorial for qtp[1]
Vb script tutorial for qtp[1]
 
CHAPTER 3 JS (1).pptx
CHAPTER 3  JS (1).pptxCHAPTER 3  JS (1).pptx
CHAPTER 3 JS (1).pptx
 
Html JavaScript and CSS
Html JavaScript and CSSHtml JavaScript and CSS
Html JavaScript and CSS
 
Javascript tutorial
Javascript tutorialJavascript tutorial
Javascript tutorial
 
JavaScript - Getting Started.pptx
JavaScript - Getting Started.pptxJavaScript - Getting Started.pptx
JavaScript - Getting Started.pptx
 
Java scripts
Java scriptsJava scripts
Java scripts
 
Javascript survival for CSBN Sophomores
Javascript survival for CSBN SophomoresJavascript survival for CSBN Sophomores
Javascript survival for CSBN Sophomores
 
First Pages HTML ASP-ASP.NET
First Pages HTML ASP-ASP.NETFirst Pages HTML ASP-ASP.NET
First Pages HTML ASP-ASP.NET
 
Basic JavaScript Tutorial
Basic JavaScript TutorialBasic JavaScript Tutorial
Basic JavaScript Tutorial
 
Placement and variable 03 (js)
Placement and variable 03 (js)Placement and variable 03 (js)
Placement and variable 03 (js)
 

More from tutorialsruby

&lt;img src="../i/r_14.png" />
&lt;img src="../i/r_14.png" />&lt;img src="../i/r_14.png" />
&lt;img src="../i/r_14.png" />tutorialsruby
 
TopStyle Help &amp; &lt;b>Tutorial&lt;/b>
TopStyle Help &amp; &lt;b>Tutorial&lt;/b>TopStyle Help &amp; &lt;b>Tutorial&lt;/b>
TopStyle Help &amp; &lt;b>Tutorial&lt;/b>tutorialsruby
 
The Art Institute of Atlanta IMD 210 Fundamentals of Scripting &lt;b>...&lt;/b>
The Art Institute of Atlanta IMD 210 Fundamentals of Scripting &lt;b>...&lt;/b>The Art Institute of Atlanta IMD 210 Fundamentals of Scripting &lt;b>...&lt;/b>
The Art Institute of Atlanta IMD 210 Fundamentals of Scripting &lt;b>...&lt;/b>tutorialsruby
 
&lt;img src="../i/r_14.png" />
&lt;img src="../i/r_14.png" />&lt;img src="../i/r_14.png" />
&lt;img src="../i/r_14.png" />tutorialsruby
 
&lt;img src="../i/r_14.png" />
&lt;img src="../i/r_14.png" />&lt;img src="../i/r_14.png" />
&lt;img src="../i/r_14.png" />tutorialsruby
 
0047ecaa6ea3e9ac0a13a2fe96f4de3bfd515c88f5d90c1fae79b956363d7f02c7fa060269
0047ecaa6ea3e9ac0a13a2fe96f4de3bfd515c88f5d90c1fae79b956363d7f02c7fa0602690047ecaa6ea3e9ac0a13a2fe96f4de3bfd515c88f5d90c1fae79b956363d7f02c7fa060269
0047ecaa6ea3e9ac0a13a2fe96f4de3bfd515c88f5d90c1fae79b956363d7f02c7fa060269tutorialsruby
 
0047ecaa6ea3e9ac0a13a2fe96f4de3bfd515c88f5d90c1fae79b956363d7f02c7fa060269
0047ecaa6ea3e9ac0a13a2fe96f4de3bfd515c88f5d90c1fae79b956363d7f02c7fa0602690047ecaa6ea3e9ac0a13a2fe96f4de3bfd515c88f5d90c1fae79b956363d7f02c7fa060269
0047ecaa6ea3e9ac0a13a2fe96f4de3bfd515c88f5d90c1fae79b956363d7f02c7fa060269tutorialsruby
 
BloggingWithStyle_2008
BloggingWithStyle_2008BloggingWithStyle_2008
BloggingWithStyle_2008tutorialsruby
 
BloggingWithStyle_2008
BloggingWithStyle_2008BloggingWithStyle_2008
BloggingWithStyle_2008tutorialsruby
 
cascadingstylesheets
cascadingstylesheetscascadingstylesheets
cascadingstylesheetstutorialsruby
 
Winter%200405%20-%20Advanced%20Javascript
Winter%200405%20-%20Advanced%20JavascriptWinter%200405%20-%20Advanced%20Javascript
Winter%200405%20-%20Advanced%20Javascripttutorialsruby
 
Winter%200405%20-%20Advanced%20Javascript
Winter%200405%20-%20Advanced%20JavascriptWinter%200405%20-%20Advanced%20Javascript
Winter%200405%20-%20Advanced%20Javascripttutorialsruby
 

More from tutorialsruby (20)

&lt;img src="../i/r_14.png" />
&lt;img src="../i/r_14.png" />&lt;img src="../i/r_14.png" />
&lt;img src="../i/r_14.png" />
 
TopStyle Help &amp; &lt;b>Tutorial&lt;/b>
TopStyle Help &amp; &lt;b>Tutorial&lt;/b>TopStyle Help &amp; &lt;b>Tutorial&lt;/b>
TopStyle Help &amp; &lt;b>Tutorial&lt;/b>
 
The Art Institute of Atlanta IMD 210 Fundamentals of Scripting &lt;b>...&lt;/b>
The Art Institute of Atlanta IMD 210 Fundamentals of Scripting &lt;b>...&lt;/b>The Art Institute of Atlanta IMD 210 Fundamentals of Scripting &lt;b>...&lt;/b>
The Art Institute of Atlanta IMD 210 Fundamentals of Scripting &lt;b>...&lt;/b>
 
&lt;img src="../i/r_14.png" />
&lt;img src="../i/r_14.png" />&lt;img src="../i/r_14.png" />
&lt;img src="../i/r_14.png" />
 
&lt;img src="../i/r_14.png" />
&lt;img src="../i/r_14.png" />&lt;img src="../i/r_14.png" />
&lt;img src="../i/r_14.png" />
 
xhtml_basics
xhtml_basicsxhtml_basics
xhtml_basics
 
xhtml_basics
xhtml_basicsxhtml_basics
xhtml_basics
 
xhtml-documentation
xhtml-documentationxhtml-documentation
xhtml-documentation
 
xhtml-documentation
xhtml-documentationxhtml-documentation
xhtml-documentation
 
CSS
CSSCSS
CSS
 
CSS
CSSCSS
CSS
 
0047ecaa6ea3e9ac0a13a2fe96f4de3bfd515c88f5d90c1fae79b956363d7f02c7fa060269
0047ecaa6ea3e9ac0a13a2fe96f4de3bfd515c88f5d90c1fae79b956363d7f02c7fa0602690047ecaa6ea3e9ac0a13a2fe96f4de3bfd515c88f5d90c1fae79b956363d7f02c7fa060269
0047ecaa6ea3e9ac0a13a2fe96f4de3bfd515c88f5d90c1fae79b956363d7f02c7fa060269
 
0047ecaa6ea3e9ac0a13a2fe96f4de3bfd515c88f5d90c1fae79b956363d7f02c7fa060269
0047ecaa6ea3e9ac0a13a2fe96f4de3bfd515c88f5d90c1fae79b956363d7f02c7fa0602690047ecaa6ea3e9ac0a13a2fe96f4de3bfd515c88f5d90c1fae79b956363d7f02c7fa060269
0047ecaa6ea3e9ac0a13a2fe96f4de3bfd515c88f5d90c1fae79b956363d7f02c7fa060269
 
HowTo_CSS
HowTo_CSSHowTo_CSS
HowTo_CSS
 
HowTo_CSS
HowTo_CSSHowTo_CSS
HowTo_CSS
 
BloggingWithStyle_2008
BloggingWithStyle_2008BloggingWithStyle_2008
BloggingWithStyle_2008
 
BloggingWithStyle_2008
BloggingWithStyle_2008BloggingWithStyle_2008
BloggingWithStyle_2008
 
cascadingstylesheets
cascadingstylesheetscascadingstylesheets
cascadingstylesheets
 
Winter%200405%20-%20Advanced%20Javascript
Winter%200405%20-%20Advanced%20JavascriptWinter%200405%20-%20Advanced%20Javascript
Winter%200405%20-%20Advanced%20Javascript
 
Winter%200405%20-%20Advanced%20Javascript
Winter%200405%20-%20Advanced%20JavascriptWinter%200405%20-%20Advanced%20Javascript
Winter%200405%20-%20Advanced%20Javascript
 

Recently uploaded

AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAndrey Devyatkin
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FMESafe Software
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsJoaquim Jorge
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdflior mazor
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘RTylerCroy
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...Neo4j
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodJuan lago vázquez
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)wesley chun
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...DianaGray10
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024The Digital Insurer
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingEdi Saputra
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processorsdebabhi2
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...apidays
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...apidays
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024Rafal Los
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024The Digital Insurer
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProduct Anonymous
 
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...Principled Technologies
 

Recently uploaded (20)

AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of Terraform
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdf
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...
 

w3schools%20javascript%20comments

  • 1. Web Authoring Name: Lesson Completion Sheet W3School JavaScript JavaScript Comments, Variables, If…Else, Switch, Operators For this lesson, you will be going through the JavaScript Comments tutorial on the W3Schools web site located at www.w3schools.com/js/js_comments.asp, then the JavaScript Variables tutorial on the W3Schools web site located at www.w3schools.com/js/js_variables.asp, then the JavaScript If…Else tutorial on the W3Schools web site located at www.w3schools.com/js/js_if_else.asp, then the JavaScript Switch tutorial on the W3Schools web site located at www.w3schools.com/js/js_statements.asp, then the JavaScript Operators tutorial on the W3Schools web site located at www.w3schools.com/js/js_operators.asp . All files that you save as part of this lesson should be saved in a folder called JavaScript Comments inside a folder called w3school javascript that you create in your network folder for this course. Assignments X X Grade Read through the JavaScript Comments tutorial. Use notepad to create an HTML document. Include a JavaScript section made up of document.write /10 statements that would create this: (use one document.write statement for each line) <h1>Athletics</h1> <h2>Boys</h2> <ul> <li>Basketball</li> <li>Soccer</li> <li>Track</li> </ul> <h2>Girls</h2> <ul> <li>Basketball</li> <li>Soccer</li> <li>Volleyball</li> </ul> - Add this multi-line comment at the beginning of the script: This script shows a list of boys and girls athletic offerings - Add a single line comment This is the list of boys sports between the Boys header and the beginning of the list. - Prevent the list item Track from being displayed by commenting it - Prevent the entire list under the Girls heading from being displayed by using a multiline comment - Add an end of line comment aka Sports to the Athletic header line Save your HTML document as comment1.htm Read through the JavaScript Variables tutorial. Look at the Variable example. Use notepad to create an HTML document that contains JavaScript code /10 that will save five different words as five different variables, then display those five words. Save your document as variable1.htm. Read through the JavaScript If..Else tutorial. Look at the If statement example. Use notepad to create an HTML document. Copy the HTML from /10 the example into your HTML document. Get rid of the stuff in the p tags. Add to the script so that the greeting “Lunch time!” if the hour value of the time is 12 (12:00-12:59pm) and “Good afternoon” if the time is greater than 12 (1pm or later). Save your document as if1.htm. I:My Documentsweb authoringassignmentsw3schools javascript basicw3schools javascript comments.docx Page 1 of 2
  • 2. Look at the If…else statement example. Use notepad to create an HTML document. Copy the HTML /10 from the example into your HTML document. Get rid of the stuff in the p tags. Change getHours in the script to getDay, this will give the day of the week, numbered 0-6 (Sunday=0, Monday=1, etc). Change the script so that on Fridays (day 5), it will display “Thank goodness its Friday!” and so that it will display “It’s not Friday yet.” On all other days. Save your document as if2.htm. Look at the If…else if…else statement example. Use notepad to create an HTML document. Copy the /10 HTML from the example into your HTML document. Get rid of the stuff in the p tags. Change getHours in the script to getMonth, this will give the month of the year, numbered 0-11. Change the script so that in January – May it will display “I can’t wait for summer”; during June, July and August, it will display “I love the summer!” and in September – December it will display “I can’t wait for summer” again. Save your document as if3.htm. Look at the Random link example. Use notepad to create an HTML document. Make an h1 header /10 that says “Coin Toss”. Include a JavaScript script that displays a picture of heads or a picture of tails.based on the random number generate in the script. Save your document as if4.htm ; Read through the JavaScript Switch tutorial. Look at the Switch Statement example. Use notepad to creat an HTML document. Write a JavaScript /10 script that uses the getMonth command to get the current month number (0-11) then displays the actual month name. Save your document as switch1.htm Read through the JavaScript Operators example. Use notepad to create an HTML document. Think of a sentence that is five words long. Write a /10 JavaScript script that stores each of these words in a variable then writes the whole sentence by “adding” these five variables together. Save your document as operator1.htm. /80 When you have completed the assignments for this lesson, staple any printouts to the back of this sheet in order and hand it in to the teacher. I:My Documentsweb authoringassignmentsw3schools javascript basicw3schools javascript comments.docx Page 2 of 2