General Instructions:

Similar documents
Chapter 3 Software Packages to Install How to Set Up Python Eclipse How to Set Up Eclipse... 42

PSYCHOLOGY HUMAN SUBJECT POOL AY

Review Questions in Introductory Knowledge... 37

Computer Science 101 Project 2: Predator Prey Model

To open a CMA file > Download and Save file Start CMA Open file from within CMA

Assignment 5: Integrative epigenomics analysis

To open a CMA file > Download and Save file Start CMA Open file from within CMA

15-110: Principles of Computing, Spring Problem Set 9 (PS9) Due: Friday, April 6 by 2:30PM via Gradescope Hand-in

Vega: Variational Segmentation for Copy Number Detection

Living with Newton's Laws

Term Paper Step-by-Step

CNV PCA Search Tutorial

Blue Distinction Centers for Fertility Care 2018 Provider Survey

Reveal Relationships in Categorical Data

Experimental Design (XPD) 2017 Rules: B/C Division

ATEP 345L Athletic Injury Evaluation I Lab Spring 2016

LAB ASSIGNMENT 4 INFERENCES FOR NUMERICAL DATA. Comparison of Cancer Survival*

PSYCHOLOGY 355: FORENSIC PSYCHOLOGY I

SAMPLING ERROI~ IN THE INTEGRATED sysrem FOR SURVEY ANALYSIS (ISSA)

School of Health Sciences PBHE 605 Quarantine 3 Credit Hours Length of Course: 8 weeks Prerequisite: None

1. Bring your completed exam to class on Monday November 10, 2014, being sure that you have made a copy for safe keeping; OR

Problem Set 2 September 18, 2009

BIOL 288: Human Anatomy & Physiology Fall 2015; MWF 12:30 1:20pm, ISC 131

Your Task: Find a ZIP code in Seattle where the crime rate is worse than you would expect and better than you would expect.

Directions for Menu Worksheet ***Updated 9/3/2014 for SY Breakfast *** General Information:

BIOL 266: Human Anatomy & Physiology II Spring 2017; MWF 1:30 2:20pm, Newton 203

Carnegie Mellon Univ. Dept. of Computer Science Database Applications

CPSC 121 Some Sample Questions for the Final Exam

All reverse-worded items were scored accordingly and are in the appropriate direction in the data set.

Personal Contract Programme (PCP) Summary Guidelines

Lab 4: Alpha and Kappa. Today s Activities. Reliability. Consider Alpha Consider Kappa Homework and Media Write-Up

Lab #3 Potentiometric Titration of Soda Ash (after Christian, p , p ) (phenolphthalein)

RISK ASSESSMENT RISK MANAGEMENT FORMS. Data Protection Act

Computer Programming

Grade 6 Math Circles Winter February 6/7 Number Theory - Solutions Warm-up! What is special about the following groups of numbers?

September 7 December 2, 2011

PROGRAMMER S SAFETY KIT: Important Points to Remember While Programming or Validating Safety Tables

Kronos Employee Self-Service New Hire Insurance Enrollment Guide

Speed Accuracy Trade-Off

Cell division occurs in a series of stages, or phases.

Assessment Task for Stage 6 Preliminary Subject: PDHPE Topic: The Body In Motion (Core 2)

Cleveland State University Department of Electrical and Computer Engineering Control Systems Laboratory. Experiment #3

E SERIES. Contents CALIBRATION PROCEDURE. Version 2.0

Grade 6 Math Circles Winter February 6/7 Number Theory

2. Determine the identity of three unknown liquid substances based on their glucose concentration.

Course Syllabus Department of Psychology The University of British Columbia

BlueBayCT - Warfarin User Guide

Forces and motion 1: Identifying forces

Authorship Guidelines for CAES Faculty Collaborating with Students

CSDplotter user guide Klas H. Pettersen

Fully Automated IFA Processor LIS User Manual

V. LAB REPORT. PART I. ICP-AES (section IVA)

PedCath IMPACT User s Guide

Reshaping of Human Fertility Database data from long to wide format in Excel

MULTIPLE LINEAR REGRESSION 24.1 INTRODUCTION AND OBJECTIVES OBJECTIVES

Student Guide to EHR Go

ALL PRINCIPAL INVESTIGATORS/NURSES/DATA MANAGERS RE: PROTOCOL GOG-0233 ACRIN 6671, REVISION # 9 & #10

Cervical Screening System AJ-CRUK Add Extra Fields. Change Request 5794

Source Deduction Table for Québec Income Tax

Parkland College Health Professions. Health Guidelines Updated December 2018

Essentials of Carbohydrate Chemistry. J. F. Robyt Springer, New York. QD 321 R (Sciences and Technology Library)

ANSC*4280 Poultry Nutrition - DRAFT

Improving Eligibility and Consent Documentation. September 20, 2012

NYSIIS. Immunization Evaluator and Manage Schedule Manual. October 16, Release 1.0

Gene Expression Analysis Web Forum. Jonathan Gerstenhaber Field Application Specialist

XRDUG Session II Edward Laitila 2/7/2009

In Class Problem Discovery of Drug Side Effect Using Study Designer

Student Minds Turl Street, Oxford, OX1 3DH

Patient Safety Queries DMARDs, Warfarin and Triple Whammy. Version th July User Guide for GP Practices SPIRE Local (v1.2.

PubHlth Introductory Biostatistics Fall 2012 Examination II Choice A Unit 2 (Introduction to Probability) Due Monday October 8, 2012

PSYCH-GA.2211/NEURL-GA.2201 Fall 2016 Mathematical Tools for Cognitive and Neural Science. Homework 5

Psychology of Perception PSYC Spring 2017 Laboratory 2: Perception of Loudness

INRODUCTION TO TREEAGE PRO

Award for a Physical Therapist

Scale Printer System. Supervisor Manual Supplement. Models SP 1500 SP 21500

Appendix C: Protocol for the Use of the Scribe Accommodation and for Transcribing Student Responses

Self Assessment 8.3 to 8.4.x

DPV. Ramona Ranz, Andreas Hungele, Prof. Reinhard Holl

Medtech32 Diabetes Get Checked II Advanced Form Release Notes

Midterm project (Part 2) Due: Monday, November 5, 2018

Palindrome Studies (Part 1)

Practice Direction Refill History Recording System

TEST & MEASUREMENT. Impossible Insights Made Possible Through Minimally Invasive Force & Pressure Measurement

(b) is as low as is reasonably practicable, where it is not reasonably practicable to meet the standard under clause (a).

WHAT IS THE DISSERTATION?

NATIONAL CERTIFICATE (VOCATIONAL) LIFE ORIENTATION (Second Paper) NQF LEVEL 2 SUPPLEMENTARY EXAMINATION 2010

BASE 24-HOUR URINE COLLECTION LITHOLINK CORE LAB

Reporting Nonviable MDH Vaccine to MIIC

Step-by-Step Protocol for the Registered Replication Report of Strack, Martin, & Stepper (1988) Eric-Jan Wagenmakers, Titia Beek, and Laura Dijkhoff

GEORGE MASON UNIVERSITY School of Recreation, Health, and Tourism. PHED 105 Aerobics and Basic Conditioning

CaseBuilder - Quick Reference Guide

ICD-10 to 9 Mapping Client User Guide

Warfarin Help Documentation

RP 9.2.2: RP 9.2.3:

easy read Your rights under THE accessible InformatioN STandard

easy read Your rights under THE accessible InformatioN STandard

Charts Worksheet using Excel Obesity Can a New Drug Help?

COMPREHENSIVE CLINICAL INTEGRATIVE PAPER

Applied Medical. Statistics Using SAS. Geoff Der. Brian S. Everitt. CRC Press. Taylor Si Francis Croup. Taylor & Francis Croup, an informa business

Part 1 Making the initial neuron connection

Transcription:

CSCE 110: Programming I Spring 2019 Lab 4 General Instructions: Lab is due online by 11:59 pm of the due date. The assignment must be typed, not handwritten or scanned. Label your Python programs q<num>.py, where num is the question number. example, your solution to the first question is stored in the file q1.py. For Make sure you read the lab before you start. Your programs must match the output exactly as given for each question. This is important as one of the keys to being a good programmer is attention to details. If you forgot to bring a computer, you can check out a temporary laptop from ZACH 8 for a few hours (depending on the availability). Grading is based on correctness and clarity. Copying work from another source and submitting it as your own is plagiarism. The minimum penalty for plagiarism is a grade of zero. 1

Lab Questions 1. Computing leap years. Write a Python program stored in a file q1.py that asks for a starting year and an ending year and then prints all of the leap years between them (and including them, if they are also leap years). Leap years are divisible by 4. However, years divisible by 100 are not leap years unless they are also divisible by 400. Example #1. The user enters 2000 and 2015 as the starting and ending years (lines 1 2). The program then outputs the leap years in this range (lines 4 8). 1 Starting year : 2000 2 Ending year : 2015 4 Leap years between 2000 and 2015 5 2000 6 2004 7 2008 8 2012 Example #2. The user enters 1881 and 1907 as the starting and ending years (lines 1 2). The program then outputs the leap years in this range (lines 4 9). 1 Starting year : 1881 2 Ending year : 1907 4 Leap years between 1881 and 1907 5 1884 6 1888 7 1892 8 1896 9 1904 2

2. Palindromic numbers. A palindromic number is a number that is the same when written forwards or backwards. Write a Python program stored in a file q2.py that asks for a starting number and an ending number, and then prints all the palindromic numbers between them (and including them, if they are also palindromic numbers). Each palindromic number, must be separated by a space. Your program should also print the number of even and odd palindromic numbers generated. The ending number should not be greater than 1000. If the ending number is greater than 1000, print an error message and exit. Example 1 Starting number : 24 2 Ending number : 151 4 Palindromic numbers between 24 and 151 5 44 55 66 77 88 99 101 111 121 11 141 151 6 7 Number of even palindromic numbers : 8 Number of odd palindromic numbers : 10

. Matrix multiplication. Write a Python program stored in a file q.py that calculates the multiplication C of two matrices (A, B) of integers and calculates the transpose T of the resulting matrix C. The program should perform the following: - Ask for the number of rows, and the number of columns of matrix A on one line. - Ask for the number of rows, and the number of columns of matrix B on one line. - Ask for the numbers in each matrix. The number of rows or columns should not exceed 10. If the matrices A and B cannot be multiplied, the program should print an error message and exit. Example 1 Enter matrix A rows and columns : 4 2 2 Enter matrix B rows and columns : 2 Enter matrix A: 1 4 5 8 9 1 1 4 Enter matrix B: 0 9 1 2 1 5 6 Matrix A: 7 1 8 4 5 9 8 9 10 1 1 11 12 Matrix B: 1 0 9 14 1 2 1 15 16 Matrix C: 17 9 12 18 5 22 41 19 9 42 81 20 1 5 10 21 22 Transpose matrix T: 2 5 9 1 24 9 22 42 5 25 12 41 81 10 4

Submitting Your Assignment Once you have completed your programs, submit each of them (q1.py, q2.py, q.py) electronically. The extra credit question is optional. You may resubmit your files as many times as you need until the due date. Only the most recent submission is graded. You are required to include the following lines in the header of all your files: # File: filename.py # Author: Student name # Date: xx/xx/2019 # Section: Student section number # E-mail: student_email@tamu.edu # Description: # e.g. This program asks for... If you are in section 501 or 502, submit your files only on: mimir.io If you are in section 50, 504, 505 or 506, submit your files only on: gradescope.com 5