IFSC 30003 HW1 Due by Wednesday Sept. 3, 2025
Directions: Answer the questions below. Answers should
be in your own words, and not unedited AI output or read like AI output. Ya' wanna exercise
your mind and learn
important things, right?
Hand
in by emailing to IFSC30003HW@gmail.com.
Put answers along with each question in body of email.
Avoid sharing a google doc because the grader might not be able to see it.
1.
Go to w3schools.com, then to its JS Tutorial section, then to
the first lesson there, linked from "JS HOME" and titled (once you
get there) "JavaScript Tutorial." Find the sandbox on that page and
go to it by clicking "Try it Yourself." · Explain
the button HTML command, except for the JavaScript code part. · Explain
the meaning of onclick, which is an attribute of the button command. · Explain
the JavaScript code assigned to the onclick argument. · What
does "demo" refer to? · What
does the function getElementById() do? · What
does innerHTML refer to? · What
does the function Date() do? 2.
Consider the "JavaScript Where To" lesson, linked
from "JS Where To." JavaScript may be placed within HTML
<script>…</script> tags. Let us call these code passages
"scripts." Can a script be placed in an HTML head, body, neither, or
both? 3.
Consider external JavaScript code. a.
Why might code be placed in an external file instead of in a
web page? b.
Find the external code file myScript.js on the W3schools
site. What is the URL of that file? 4.
Consider the "JavaScript Output" lesson linked from
"JS Output." a.
Write an HTML page (you can use a sandbox from "JS
HOME" or elsewhere) that has 4 buttons on it. One button demonstrates
output to the innerHTML location of an HTML element. Another button demonstrates
(when you click it) the document.write() output method. A third button
demonstrates output using the alert() function. And a final button calls
window.print(). b.
Consider output using console.log(). Explain what you see in
the console, or provide a screen shot of the console containing a logged
output. 5.
Learn about quote symbols in JavaScript.
6.
Using an AI, ask it to generate a web page with embedded JavaScript code that satisfies a specification that you
provide. Test it in a w3schools.com sandbox (or some other way). Evaluate: how well does the page meet your
specifications? Hand in your specification, the source code of the page you generated, and your evaluation.
7.
(5 pts.) In this course a more mathematically reasonable scoring model is used for scoring HWs.
In this course, what is the minimum score on a HW, such as for a HW that is not handed in?
< < < < Hand in the code by pasting it into the body of
your email.
Use https://claude.ai/public/artifacts/aa820d6a-7b91-4d07-a04a-53bd77897b58.
(The previous version at https://claude.ai/public/artifacts/830f3187-24ba-45bd-ad97-899d668d6541
is algorithmically the same but has a user experience deficiency.)
Hand in a screen shot showing that you finished it.
Evaluate: what do you
think of the quality of this AI-generated app?