Lab 1 Concert Ticket Calculator
|
|
- Lee Higgins
- 5 years ago
- Views:
Transcription
1 Lab 1 Concert Ticket Calculator Purpose To assess your ability to apply the knowledge and skills developed in weeks 1 through 3. Emphasis will be placed on the following learning outcomes: 1. Create and display simple syntactically correct HTML documents. 2. Describe the execution a JavaScript program in a web browser. 3. Write and call functions that utilize parameters and return values. 4. Declare, define, and use variables in a script. 5. Correctly use the JavaScript "if" and nested "if-else if" statements. Assignment Your local school is going to host a concert. They need a web page for the school staffs to determine the concert ticket costs. You are tasked to design and build the concert ticket calculator for the school. There are four type of tickets. They are front row, middle row, rear row and balcony. The ticket costs are. Front row: Middle row: Rear row: Balcony: $12.50 per ticket $10 per ticket $7.50 per ticket $14.50 per ticket Presume all seats are purchased at once and are in the same seating location. Regardless of location, if 6 or more tickets are purchased, 12% will be deducted from the final total. Students get additional 15% discount. For example, for 8 tickets without student discount, the web page should output: Front row seats for 8 tickets will cost $88.00 Middle row seats for 8 tickets will cost $70.40 Rear row seats for 8 tickets will cost $52.80 Balcony seats for 8 tickets will cost $ For 8 tickets with student discount, the web page should output: Front row seats for 8 tickets will cost $74.80 Middle row seats for 8 tickets will cost $59.84 Rear row seats for 8 tickets will cost $44.88 Balcony seats for 8 tickets will cost $ x 8 = % discount for 6 or more tickets, the total ticket cost is $ And for student 15% discount, the total ticket cost is $ Verify the calculation.
2 Action Items/Programming Requirements The solution must use and deliver both an HTML and a JS file. The JS file must be referenced in the <head> tag of the HTML document using the <script> tag to load your function so it can be called later on. The solution should use a <script> in the <body> of the HTML to call the main weather function. All JS files must contain the strict directive at the top. This directive allows the debugger to flag undeclared variables. "use strict"; All variables must be declared. The prompt() function must be used to gather information from the user just as was done in the example screen shots. Do not use <input> tags or hard coded input values. If function has parameters, the function parameters must be utilized. No global variables are allowed. Function Requirements You should have these functions. o A ticket calculation condition function: This function three parameters: Seating location such as Front, Middle, Rear, or Balcony Number of tickets Is student Boolean The function must be in a JS file. All functions should always be in JS files and multiple separate functions can be in the same JS file. The function is responsible for calculating and returning the total ticket cost for the requested number of tickets for the given seat location with or without student discount. Your function should be reusable. If done correctly, the parameters provide everything needed to calculate the ticket cost. Call the function four times to get the information you need for all output. The code inside the function may NOT prompt the user nor write to the web page. The function parameters are sufficient to allow the function code to calculate the costs and return the answer. The JavaScript that calls the function should handle prompting and output to the web page. The calling code should output four HTML bullet points displaying the total cost of the requested number of tickets for seating at ALL four seating locations. o An utility isstudent function: Return true if user answers "Y" or "y" to student discount question. False otherwise. See the sample output screen shots. o (Optional) A main function: Having a main function help organize the overall flow of the program. This function prompts for user inputs and call the ticket cost calculation function and displays the results. Put the HTML and JS files in the same folder. Try to make your solution look similar to the screen shots. Put identifying information in your files: your name, assignment name/number term/class.
3 Example for HTML: <!-- YourName Lab SU-ITEC136 --> Example for JS: /** YourName * Lab SU-ITEC 136 */ Review code against the documentation and style requirements Word document available on the course web site for the assignment. You will find that both documentation and style requirements are facilitated by the Aptana Integrated Development Environment (IDE).
4 Screen Shots (FireFox): With student discount:
5 Screen Shots (FireFox): Without student discount:
6 Helpful Hints The following hints may help you to solve the problem: The JavaScript file must have "use strict"; directive. Use the prompt() function to input data. For example: var favcolor = prompt("what is your favorite color?", "yellow ); The first parameter is shown to the user and the second parameter is the optional default response. Recall that prompt() returns a string value. Use the parsefloat() function to convert a string into a floating point number. After the JavaScript below, receipttotal will hold a floating point value with decimal precision, ready to be used in math operations. Likewise, num variable can have decimal value. var numberasstring = "6.023"; var receipttotal = parsefloat(numberasstring); var num = parsefloat(prompt("what is 5 / 2?")); Use the parseint() function to convert a string into an integer number. After the JavaScript below, totalpeople will hold a whole number value of 123, ready to be used in math operations. Likewise, age variable only hold integer value. var totalpeopleasstring = "123"; var totalpeople = parseint(totalpeopleasstring); var age = parseint(prompt("how old are you?")); Use the tofixed() method of any Number object (variable) to convert a number into a string with a fixed number of decimal places. For example: var mypi = ; document.writeln(mypi.tofixed(4)); // writes out Use Math.round() to round a number to the nearest integer only. var wholenum = Math.round(20.49); // Returns 20 into wholenum wholenum = Math.round(20.99); // Returns 21 into wholenum You could use the.tofixed() method of any Number object (variable) to convert a number into a string with a fixed number of decimal places. But.toFixed() is meant to convert to strings, not round number variables. Additionally, while.tofixed() may round most values, there is a problem with it on some numbers. For example, this works fine: var mypi = ; document.writeln(mypi.tofixed(4)); // writes out This does not:
7 var val = 1.045; var n = val.tofixed(2); document.writeln("n == " + n + "<br>"); // 1.04, WRONG! Should be 1.05 Use the following to properly display number to the 2 decimal place, var val = 1.045; val = Math.round(val * 100)/100; var n = val.tofixed(2); Better yet, write a function to return the number with two decimal places. function round(value) { return (Math.round(value * 100) / 100); } var val = 1.045; var n = round(val).tofixed(2); If a variable represents U.S. currency, we expect to see it displayed with two places of decimal precision. Even if there is only one place of decimal precision in the value. For example, a variable holds 1.5; when output to the web page it will appear as 1.5 this rather than 1.50 as preferred. Even though.tofixed() isn't a good choice for rounding, it is very good at zero padding. Use it for output of monetary values as calculated values may have only one decimal place of precision. Use document.writeln() to display output to user.
8 Grading Criteria Quality of the solution: 0 50 points o Documentation (internal comments) (0 5 points) It is not uncommon for industry to impose a way of documenting software that is uniform across all programmers. Documentation standards are outlined in the same document referenced in the style bullet below. o Style (formatting, naming conventions and appearance of solution code) (0 5 points) As listed in the action items of the course web page lab assignment, ensure that your solution code meets the documentation and style guidelines for this course. The documentation and style requirements Word document titled "DocumentationAndStyleGuidelines.doc exists in the Resources folder on your course CD and as a link on the lab assignment page web page. Review your code against this document. I am looking for consistency also. For example, if you prefer to put your curly braces on the same line as the if statement rather than the next line, that is fine provided you are consistent throughout your code. o Correctness (how the program works under test) (0 40 points) The program should work, and be seen to work. The code should be robust. Note that grammar, spelling, and writing mechanics do not contribute to the total points for this assignment; however, improper grammar, poor spelling, or poor writing mechanics may result in significant point deductions.
Lab 2 Population. Purpose. Assignment Lab 2 analyzes population growth of a town as well as compare the population growth of two towns.
Lab 2 Population Purpose To assess your ability to apply the knowledge and skills developed up though week 7. Emphasis will be placed on the following learning outcomes: 1. Decompose a problem into modularized
More informationLab 1. Purpose. Assignment. Action Items/Programming Requirements
Lab 1 Purpose To assess your ability to apply the knowledge and skills developed in weeks 1 through 4. Emphasis will be placed on the following learning outcomes: 1. Create and display simple syntactically
More informationLab 3 - Pizza. Purpose. Assignment
Lab 3 - Pizza Purpose To assess your ability to apply the knowledge and skills developed in weeks 1 through 9. Emphasis will be placed on the following learning outcomes: 1. Create syntactically correct
More informationITEC136 - Lab 2 Population
ITEC136 - Lab 2 Population Purpose To assess your ability to apply the knowledge and skills developed up though week 7. Emphasis will be placed on the following learning outcomes: 1. Decompose a problem
More informationc122mar413.notebook March 06, 2013
These are the programs I am going to cover today. 1 2 Javascript is embedded in HTML. The document.write() will write the literal Hello World! to the web page document. Then the alert() puts out a pop
More informationAssessment - Unit 3 lessons 16-21
Name(s) Period Date Assessment - Unit 3 lessons 16-21 1. Which of the following statements about strings in JavaScript is FALSE? a. Strings consist of a sequence of concatenated ASCII characters. b. Strings
More informationExercise 1 Using Boolean variables, incorporating JavaScript code into your HTML webpage and using the document object
CS1046 Lab 5 Timing: This lab should take you approximately 2 hours. Objectives: By the end of this lab you should be able to: Recognize a Boolean variable and identify the two values it can take Calculate
More informationCSCI 3300 Assignment 3
Austin Peay State University, Tennessee Fall 2016 CSCI 3300: Introduction to Web Development Dr. Leong Lee CSCI 3300 Assignment 3 Total estimated time for this assignment: 10 hours When you see Richard
More informationLesson 7: If Statement and Comparison Operators
JavaScript 101 7-1 Lesson 7: If Statement and Comparison Operators OBJECTIVES: In this lesson you will learn about Branching or conditional satements How to use the comparison operators: ==,!=, < ,
More informationWorking with JavaScript
Working with JavaScript Creating a Programmable Web Page for North Pole Novelties 1 Objectives Introducing JavaScript Inserting JavaScript into a Web Page File Writing Output to the Web Page 2 Objectives
More informationProgramming language components
Programming language components syntax: grammar rules for defining legal statements what's grammatically legal? how are things built up from smaller things? semantics: what things mean what do they compute?
More informationTask 1. Set up Coursework/Examination Weights
Lab02 Page 1 of 6 Lab 02 Student Mark Calculation HTML table button textbox JavaScript comments function parameter and argument variable naming Number().toFixed() Introduction In this lab you will create
More informationCMPT 100 : INTRODUCTION TO
CMPT 100 : INTRODUCTION TO COMPUTING TUTORIAL #5 : JAVASCRIPT 2 GUESSING GAME 1 By Wendy Sharpe BEFORE WE GET STARTED... If you have not been to the first tutorial introduction JavaScript then you must
More informationChapter 3 - Simple JavaScript - Programming Basics. Lesson 1 - JavaScript: What is it and what does it look like?
Chapter 3 - Simple JavaScript - Programming Basics Lesson 1 - JavaScript: What is it and what does it look like? PP presentation JavaScript.ppt. Lab 3.1. Lesson 2 - JavaScript Comments, document.write(),
More informationCOMS W3101: SCRIPTING LANGUAGES: JAVASCRIPT (FALL 2017)
COMS W3101: SCRIPTING LANGUAGES: JAVASCRIPT (FALL 2017) RAMANA ISUKAPALLI RAMANA@CS.COLUMBIA.EDU 1 LECTURE-1 Course overview See http://www.cs.columbia.edu/~ramana Overview of HTML Formatting, headings,
More informationContents. Jairo Pava COMS W4115 June 28, 2013 LEARN: Language Reference Manual
Jairo Pava COMS W4115 June 28, 2013 LEARN: Language Reference Manual Contents 1 Introduction...2 2 Lexical Conventions...2 3 Types...3 4 Syntax...3 5 Expressions...4 6 Declarations...8 7 Statements...9
More informationCSCI 3300 Assignment 3
Austin Peay State University, Tennessee Spring 2014 CSCI 3300: Introduction to Web Development Dr. Leong Lee CSCI 3300 Assignment 3 When you see Richard Ricardo in the example screen captures, change it
More informationJavascript Lesson 3: Controlled Structures ANDREY KUTASH
Javascript Lesson 3: Controlled Structures ANDREY KUTASH 10.1 Introduction Before programming a script have a Thorough understanding of problem Carefully planned approach to solve it When writing a script,
More informationintrojs.notebook March 02, 2014
1 document.write() uses the write method to write on the document. It writes the literal Hello World! which is enclosed in quotes since it is a literal and then enclosed in the () of the write method.
More informationCOMP519 Practical 5 JavaScript (1)
COMP519 Practical 5 JavaScript (1) Introduction This worksheet contains exercises that are intended to familiarise you with JavaScript Programming. While you work through the tasks below compare your results
More informationChapter 17. Fundamental Concepts Expressed in JavaScript
Chapter 17 Fundamental Concepts Expressed in JavaScript Learning Objectives Tell the difference between name, value, and variable List three basic data types and the rules for specifying them in a program
More informationحميد دانشور H_danesh_2000@yahoo.com 1 JavaScript Jscript VBScript Eg 2 JavaScript: the first Web scripting language, developed by Netscape in 1995 syntactic similarities
More informationPrincess Nourah bint Abdulrahman University. Computer Sciences Department
Princess Nourah bint Abdulrahman University 1 And use http://www.w3schools.com/ JavaScript Objectives Introduction to JavaScript Objects Data Variables Operators Types Functions Events 4 Why Study JavaScript?
More informationCOMS 469: Interactive Media II
COMS 469: Interactive Media II Agenda Review Data Types & Variables Decisions, Loops, and Functions Review gunkelweb.com/coms469 Review Basic Terminology Computer Languages Interpreted vs. Compiled Client
More informationArrays Structured data Arrays What is an array?
The contents of this Supporting Material document have been prepared from the Eight units of study texts for the course M150: Date, Computing and Information, produced by The Open University, UK. Copyright
More informationWeek 1 - Overview of HTML and Introduction to JavaScript
ITEC 136 Business Programming Concepts Week 1 Module 1: Overview of HTML and Course overview Agenda This week s expected outcomes This week s topics This week s homework Upcoming deadlines Questions and
More informationLet's Look Back. We talked about how to create a form in HTML. Forms are one way to interact with users
Introduction to PHP Let's Look Back We talked about how to create a form in HTML Forms are one way to interact with users Users can enter information into forms which can be used by you (programmer) We
More informationJAVASCRIPT BASICS. Type-Conversion in JavaScript. Type conversion or typecasting is one of the very important concept in
Type-Conversion in JavaScript Description Type conversion or typecasting is one of the very important concept in JavaScript. It refers to changing an entity or variable from one datatype to another. There
More informationControlled Assessment Task. Question 1 - Describe how this HTML code produces the form displayed in the browser.
Controlled Assessment Task Question 1 - Describe how this HTML code produces the form displayed in the browser. The form s code is displayed in the tags; this creates the object which is the visible
More informationCIS 228 (Spring, 2012) Final, 5/17/12
CIS 228 (Spring, 2012) Final, 5/17/12 Name (sign) Name (print) email I would prefer to fail than to receive a grade of or lower for this class. Question 1 2 3 4 5 6 7 8 9 A B C D E TOTAL Score CIS 228,
More informationCITS1231 Web Technologies. JavaScript Math, String, Array, Number, Debugging
CITS1231 Web Technologies JavaScript Math, String, Array, Number, Debugging Last Lecture Introduction to JavaScript Variables Operators Conditional Statements Program Loops Popup Boxes Functions 3 This
More informationSuch JavaScript Very Wow
Such JavaScript Very Wow Lecture 9 CGS 3066 Fall 2016 October 20, 2016 JavaScript Numbers JavaScript numbers can be written with, or without decimals. Extra large or extra small numbers can be written
More informationProject 2: After Image
Project 2: After Image FIT100 Winter 2007 Have you ever stared at an image and noticed that when it disappeared, a shadow of the image was still briefly visible. This is called an after image, and we experiment
More informationUnit 6 - Software Design and Development LESSON 4 DATA TYPES
Unit 6 - Software Design and Development LESSON 4 DATA TYPES Previously Paradigms Choice of languages Key features of programming languages sequence; selection eg case, if then else; iteration eg repeat
More informationCOMP284 Scripting Languages Lecture 14: JavaScript (Part 1) Handouts
COMP284 Scripting Languages Lecture 14: JavaScript (Part 1) Handouts Ullrich Hustadt Department of Computer Science School of Electrical Engineering, Electronics, and Computer Science University of Liverpool
More informationFor Project 1H, you will need the following file: w01h_casting_call You will save your document as: Lastname_Firstname_1H_Casting_Call
GO! Fix It Project 1H Casting Call For Project 1H, you will need the following file: w01h_casting_call You will save your document as: Lastname_Firstname_1H_Casting_Call 1Word In this project, you will
More informationCOMPSCI 120 Fall 2017 Review Questions for Midterm #2 Professor William T. Verts
COMPSCI 120 Fall 2017 Review Questions for Midterm #2 Professor William T. Verts UNIX What do the 9 permission letters represent (rwxrwxrwx)? How do you know if you have the permission or not? What is
More information(Simple) JavaScript Framework Homework
(Simple) JavaScript Framework Homework Overview: In this homework you will implement a picture gallery using object oriented JavaScript code in an external JavaScript file. This is a lab about learning
More informationCSCI 1100L: Topics in Computing Lab Lab 11: Programming with Scratch
CSCI 1100L: Topics in Computing Lab Lab 11: Programming with Scratch Purpose: We will take a look at programming this week using a language called Scratch. Scratch is a programming language that was developed
More informationBoolean evaluation and if statements. Making decisions in programs
Boolean evaluation and if statements Making decisions in programs Goals By the end of this lesson you will be able to: Understand Boolean logic values Understand relational operators Understand if and
More informationCSCI 3300 Assignment 6
Austin Peay State University, Tennessee Spring 2016 CSCI 3300: Introduction to Web Development Dr. Leong Lee CSCI 3300 Assignment 6 Total estimated time for this assignment: 9 hours When you see Richard
More informationManju Muralidharan Priya. CS4PM Web Aesthetics and Development WEEK 11
CS4PM Web Aesthetics and Development WEEK 11 Objective: Understand basics of JScript Outline: a. Basics of JScript Reading: Refer to w3schools websites and use the TRY IT YOURSELF editor and play with
More informationwrite vs. writeln Prompting as Page Loads Today s Goals CSCI 2910 Client/Server-Side Programming Intermediate File vs. HTML Output
CSCI 2910 Client/Server-Side Programming Topic: JavaScript Part 2 Today s Goals Today s lecture will cover: More objects, properties, and methods of the DOM The Math object Introduction to form validation
More informationLecture 14. Introduction to JavaScript. Mr. Mubashir Ali Lecturer (Dept. of Computer Science)
Lecture 14 Introduction to JavaScript Mr. Mubashir Ali Lecturer (Dept. of dr.mubashirali1@gmail.com 1 Outline What is JavaScript? Embedding JavaScript with HTML JavaScript conventions Variables in JavaScript
More informationSELECTION. (Chapter 2)
SELECTION (Chapter 2) Selection Very often you will want your programs to make choices among different groups of instructions For example, a program processing requests for airline tickets could have the
More informationIntroduction to Computer Science and Business
Introduction to Computer Science and Business The Database Programming with PL/SQL course introduces students to the procedural language used to extend SQL in a programatic manner. This course outline
More information1/6/ :28 AM Approved New Course (First Version) CS 50A Course Outline as of Fall 2014
1/6/2019 12:28 AM Approved New Course (First Version) CS 50A Course Outline as of Fall 2014 CATALOG INFORMATION Dept and Nbr: CS 50A Title: WEB DEVELOPMENT 1 Full Title: Web Development 1 Last Reviewed:
More informationCreative Computing Course Syllabus 1 semester for High School (110 contact hours)
CodeHS Creative Computing Course Syllabus 1 semester for High School (110 contact hours) Course Overview and Goals The Creative Computing course is a first year computer science course introducing the
More informationCECS 189D EXAMINATION #1
CECS 189D EXAMINATION #1 SPRING 10 70 points MULTIPLE CHOICE 2 points for each correct answer Identify the choice that best answers the question on a Scantron 882 with a pencil #2. When you're on the campus
More informationCSCI 3300 Assignment 4
Austin Peay State University, Tennessee Fall 2016 CSCI 3300: Introduction to Web Development Dr. Leong Lee CSCI 3300 Assignment 4 Total estimated time for this assignment: 7 hours When you see Richard
More informationCSC Web Programming. Introduction to JavaScript
CSC 242 - Web Programming Introduction to JavaScript JavaScript JavaScript is a client-side scripting language the code is executed by the web browser JavaScript is an embedded language it relies on its
More informationClient-Side Web Technologies. JavaScript Part I
Client-Side Web Technologies JavaScript Part I JavaScript First appeared in 1996 in Netscape Navigator Main purpose was to handle input validation that was currently being done server-side Now a powerful
More informationPES DEGREE COLLEGE BANGALORE SOUTH CAMPUS 1 K.M. before Electronic City, Bangalore WEB PROGRAMMING Solution Set II
PES DEGREE COLLEGE BANGALORE SOUTH CAMPUS 1 K.M. before Electronic City, Bangalore 560 100 WEB PROGRAMMING Solution Set II Section A 1. This function evaluates a string as javascript statement or expression
More informationCpSc 1111 Lab 4 Part a Flow Control, Branching, and Formatting
CpSc 1111 Lab 4 Part a Flow Control, Branching, and Formatting Your factors.c and multtable.c files are due by Wednesday, 11:59 pm, to be submitted on the SoC handin page at http://handin.cs.clemson.edu.
More informationInternet & World Wide Web How to Program, 5/e by Pearson Education, Inc. All Rights Reserved.
Internet & World Wide Web How to Program, 5/e Sequential execution Execute statements in the order they appear in the code Transfer of control Changing the order in which statements execute All scripts
More informationCIS 1350 Final Project Part 1 of 4
CIS 1350 Final Project Part 1 of 4 IMPORTANT NOTE: All the work you do in this section should be uploaded to the assignment drop box. Do NOT upload to the server. Failure to follow this warning will result
More informationJavaScript: Control Statements I Pearson Education, Inc. All rights reserved.
1 7 JavaScript: Control Statements I 2 Let s all move one place on. Lewis Carroll The wheel is come full circle. William Shakespeare How many apples fell on Newton s head before he took the hint! Robert
More informationExercise 1: Basic HTML and JavaScript
Exercise 1: Basic HTML and JavaScript Question 1: Table Create HTML markup that produces the table as shown in Figure 1. Figure 1 Question 2: Spacing Spacing can be added using CellSpacing and CellPadding
More informationMark Scheme. Additional Sample Assessment Materials. Pearson BTEC Level 3 - Computing. Unit 1: Principles of Computer Science
Scheme Additional Sample Assessment Materials Pearson BTEC Level 3 - Computing Unit 1: Principles of Computer Science Edexcel and BTEC Qualifications Edexcel and BTEC qualifications come from Pearson,
More informationCourse Description This one-day instructor-led course provides students with an overview of the features and functions of Microsoft Word 2010.
Module Title : Course 50541A : Learn Microsoft Word 2010 Step by Step, Level 1 Duration : 1 day Course Description This one-day instructor-led course provides students with an overview of the features
More informationPIC 40A. Midterm 1 Review
PIC 40A Midterm 1 Review XHTML and HTML5 Know the structure of an XHTML/HTML5 document (head, body) and what goes in each section. Understand meta tags and be able to give an example of a meta tags. Know
More informationGRAPHIC WEB DESIGNER PROGRAM
NH111 Outlook Level 1 16 Total Hours COURSE TITLE: Outlook Level 1 COURSE OVERVIEW: This course provides students with the knowledge and skills to utilize Microsoft Outlook to manage all aspects of email
More informationAssignment 2: Website Development
Assignment 2: Website Development Overview In this second assignment, you are required to develop your personal website from scratch, based on the design document that you created in Assignment 1. You
More information2018 Computing Science. National 5. Finalised Marking Instructions
National Qualifications 208 208 Computing Science National 5 Finalised Marking Instructions Scottish Qualifications Authority 208 The information in this publication may be reproduced to support SQA qualifications
More informationITSE 1411 Beg. Web Programming
(JavaScript, Sequence, Functions) Last revised: 4/17/14 Directions: Perform the tasks below on your personal computer or a lab computer. This document shows the score points for each task in parentheses.
More informationFunctions, Randomness and Libraries
Functions, Randomness and Libraries 1 Predefined Functions recall: in mathematics, a function is a mapping from inputs to a single output e.g., the absolute value function: -5 5, 17.3 17.3 in JavaScript,
More informationGuidelines for doing the short exercises
1 Short exercises for Murach s HTML5 and CSS Guidelines for doing the short exercises Do the exercise steps in sequence. That way, you will work from the most important tasks to the least important. Feel
More informationOutcomes Week 2 Overview Describe the inputs, activities, and outputs of each step in the software development life cycle. Describe arithmetic, relati
ITEC 136 Business Programming Concepts Week 02, Part 01 Overview 1 Week 2 Overview Week 1 review HTML documents Document Type Definition Elements (tags) Attributes Entities Inline and external JavaScript
More informationConcepts Review. 2. A program is the implementation of an algorithm in a particular computer language, like C and C++.
Concepts Review 1. An algorithm is a sequence of steps to solve a problem. 2. A program is the implementation of an algorithm in a particular computer language, like C and C++. 3. A flowchart is the graphical
More informationCSCI 3300 Assignment 7
Austin Peay State University, Tennessee Spring 2015 CSCI 3300: Introduction to Web Development Dr. Leong Lee CSCI 3300 Assignment 7 Total estimated time for this assignment: 12 hours When you see Richard
More informationSoftware Development Techniques. 26 November Marking Scheme
Software Development Techniques 26 November 2015 Marking Scheme This marking scheme has been prepared as a guide only to markers. This is not a set of model answers, or the exclusive answers to the questions,
More informationHTML5 and CSS3 More JavaScript Page 1
HTML5 and CSS3 More JavaScript Page 1 1 HTML5 and CSS3 MORE JAVASCRIPT 3 4 6 7 9 The Math Object The Math object lets the programmer perform built-in mathematical tasks Includes several mathematical methods
More informationCS1110 Lab 6 (Mar 17-18, 2015)
CS1110 Lab 6 (Mar 17-18, 2015) First Name: Last Name: NetID: The lab assignments are very important and you must have a CS 1110 course consultant tell CMS that you did the work. (Correctness does not matter.)
More informationCSCI 3300 Assignment 7
Austin Peay State University, Tennessee Fall 2016 CSCI 3300: Introduction to Web Development Dr. Leong Lee CSCI 3300 Assignment 7 Total estimated time for this assignment: 12 hours When you see Richard
More informationCpSc 1011 Lab 4 Formatting and Flow Control Windchill Temps
CpSc 1011 Lab 4 Formatting and Flow Control Windchill Temps Overview By the end of the lab, you will be able to: use fscanf() to accept inputs from the user and use fprint() for print statements to the
More informationObject Oriented Programming with Java
Object Oriented Programming with Java What is Object Oriented Programming? Object Oriented Programming consists of creating outline structures that are easily reused over and over again. There are four
More informationGraded Project. Microsoft Excel
Graded Project Microsoft Excel INTRODUCTION 1 PROJECT SCENARIO 2 CREATING THE WORKSHEET 2 GRAPHING YOUR RESULTS 4 INSPECTING YOUR COMPLETED FILE 6 PREPARING YOUR FILE FOR SUBMISSION 6 Contents iii Microsoft
More informationImportant Java terminology
1 Important Java terminology The information we manage in a Java program is either represented as primitive data or as objects. Primitive data פרימיטיביים) (נתונים include common, fundamental values as
More informationwhile (condition) { body_statements; for (initialization; condition; update) { body_statements;
ITEC 136 Business Programming Concepts Week 01, Part 01 Overview 1 Week 7 Overview Week 6 review Four parts to every loop Initialization Condition Body Update Pre-test loops: condition is evaluated before
More informationVariables and Functions. ROBOTC Software
Variables and Functions ROBOTC Software Variables A variable is a space in your robots memory where data can be stored, including whole numbers, decimal numbers, and words Variable names follow the same
More informationvar num1 = prompt("enter a number between 1 and 12","1"); var promptstring = "What is " + num1 + " times 3?"; var num2 = prompt(promptstring);
JavaScript Week 2: Last week we learned about the document, which is your html page, and document.write, which is one way in which javascript allows you to write html code to your web page. We also learned
More informationCS 106 Introduction to Computer Science I
CS 106 Introduction to Computer Science I 05 / 31 / 2017 Instructor: Michael Eckmann Today s Topics Questions / Comments? recap and some more details about variables, and if / else statements do lab work
More informationSoftware Development Techniques. December Sample Exam Marking Scheme
Software Development Techniques December 2015 Sample Exam Marking Scheme This marking scheme has been prepared as a guide only to markers. This is not a set of model answers, or the exclusive answers to
More informationAuthoring Numerical Problems in LON- CAPA: Step- by- Step
Authoring Numerical Problems in LON- CAPA: Step- by- Step 5/22/14 M. Lucas (lucasm@ohio.edu or LON- CAPA Username lucas:ohiou) Version 0.2 Overview The goal of this document is to discuss the coding of
More informationCOMP 202 Java in one week
COMP 202 Java in one week... Continued CONTENTS: Return to material from previous lecture At-home programming exercises Please Do Ask Questions It's perfectly normal not to understand everything Most of
More informationAssignment front sheet
Assignment front sheet Learning Outcome LO 3 Learning Outcome Be able to implement interactive websites Assessment Criteria In this assessment you will have the opportunity to present evidence that shows
More informationINFS 2150 Introduction to Web Development and e-commerce Technology. Programming with JavaScript
INFS 2150 Introduction to Web Development and e-commerce Technology Programming with JavaScript 1 Objectives JavaScript client-side programming Example of a JavaScript program The element
More informationIntro to Programming. Unit 7. What is Programming? What is Programming? Intro to Programming
Intro to Programming Unit 7 Intro to Programming 1 What is Programming? 1. Programming Languages 2. Markup vs. Programming 1. Introduction 2. Print Statement 3. Strings 4. Types and Values 5. Math Externals
More informationObjectives. Introduction to JavaScript. Introduction to JavaScript INFS Peter Y. Wu, RMU 1
Objectives INFS 2150 Introduction to Web Development and e-commerce Technology Programming with JavaScript JavaScript client-side programming Example of a JavaScript program The element
More informationTitle: Jan 29 11:03 AM (1 of 23) Note that I have now added color and some alignment to the middle and to the right on this example.
Title: Jan 29 11:03 AM (1 of 23) Note that I have now added color and some alignment to the middle and to the right on this example. Sorry about these half rectangle shapes a Smartboard issue today. To
More informationYear 8 Computing Science End of Term 3 Revision Guide
Year 8 Computing Science End of Term 3 Revision Guide Student Name: 1 Hardware: any physical component of a computer system. Input Device: a device to send instructions to be processed by the computer
More informationCSCI 131, Midterm Exam 1 Review Questions This sheet is intended to help you prepare for the first exam in this course. The following topics have
CSCI 131, Midterm Exam 1 Review Questions This sheet is intended to help you prepare for the first exam in this course. The following topics have been covered in the first 5 weeks of the course. The exam
More informationDecisions, Decisions. Testing, testing C H A P T E R 7
C H A P T E R 7 In the first few chapters, we saw some of the basic building blocks of a program. We can now make a program with input, processing, and output. We can even make our input and output a little
More informationSession 3: JavaScript - Structured Programming
INFM 603: Information Technology and Organizational Context Session 3: JavaScript - Structured Programming Jimmy Lin The ischool University of Maryland Thursday, September 25, 2014 Source: Wikipedia Types
More informationChipRider AQA GCSE Computer Science Mobile Assignment
ChipRider AQA GCSE Computer Science Mobile Assignment 1. Design of solution 2. Solution Development 3. Programming Techniques Used 4. Testing and Evaluation 1 Design of Solution What the problem involves
More information3 The Building Blocks: Data Types, Literals, and Variables
chapter 3 The Building Blocks: Data Types, Literals, and Variables 3.1 Data Types A program can do many things, including calculations, sorting names, preparing phone lists, displaying images, validating
More informationText Input and Conditionals
Text Input and Conditionals Text Input Many programs allow the user to enter information, like a username and password. Python makes taking input from the user seamless with a single line of code: input()
More informationCoding in JavaScript functions
Coding in JavaScript functions A function contains code that will be executed by an event or by a call to the function. You may call a function from anywhere within a page (or even from other pages if
More informationCGS 3066: Spring 2015 JavaScript Reference
CGS 3066: Spring 2015 JavaScript Reference Can also be used as a study guide. Only covers topics discussed in class. 1 Introduction JavaScript is a scripting language produced by Netscape for use within
More informationGraded Project. Microsoft Excel
Graded Project Microsoft Excel INTRODUCTION 1 PROJECT SCENARIO 1 CREATING THE WORKSHEET 2 GRAPHING YOUR RESULTS 4 INSPECTING YOUR COMPLETED FILE 6 PREPARING YOUR FILE FOR SUBMISSION 6 Contents iii Microsoft
More information