Lab III – Linux at UMBC.

Slides:



Advertisements
Similar presentations
HTML II Formatting the Language of the Web Terry Bake
Advertisements

Extended DISC Online System User Instruction: How to Run a Team Analysis.
How to Use Google Docs and Google Drive
Introduction to Python
ENEE150: Discussion 1 Section 0104 Please Sit Down at a Computer and Login!
1 Class motto: What’s this button for?. 2 CMSC104 Problem Solving and Computer Programming Fall 2011 Section 4 Richard Chang.
CSCI 1411 FUNDAMENTALS OF COMPUTING LAB Lab Introduction 1 Shane Transue MSCS.
Introducing the Command Line CMSC 121 Introduction to UNIX Much of the material in these slides was taken from Dan Hood’s CMSC 121 Lecture Notes.
Kabel Nathan Stanwicks, Head Circulation and Media Services Department Electronic Reserves Introductory Tutorial for Faculty.
CIS101 Introduction to Computing Week 05. Agenda Your questions CIS101 Survey Introduction to the Internet & HTML Online HTML Resources Using the HTML.
In an internet browser type: If you have never used this software before, click on create an account. If you have used ilrn, click on Sign.
CS1020: Intro Workshop. Topics CS1020Intro Workshop Login to UNIX operating system 2. …………………………………… 3. …………………………………… 4. …………………………………… 5. ……………………………………
Creating and Publishing Your own website
CMSC 104, Version 9/011 Introduction to C Topics Compilation Using the gcc Compiler The Anatomy of a C Program 104 C Programming Standards and Indentation.
Engineering H192 - Computer Programming The Ohio State University Gateway Engineering Education Coalition Lect 4P. 1Winter Quarter Introduction to UNIX.
Editing Java programs with the BlueJ IDE. Working environments to develop (= write) programs There are 2 ways to develop (write) computer programs: 1.Using.
Toll Free: Project Manager Tutorial.
CSE 326: Your Computing Environment Steve Martin Aiman Erbad.
Agenda What is Computer Programming? The Programming Process
Panorama High School E.G.P./ Training to Put Students’ Grades on the Website Wednesday, September 29,
Eucalyptus Virtual Machines Running Maven, Tomcat, and Mysql.
CS105 Lab 1 – Introduction Section: ??? TA: ??? ??? Announcements CITES Accounts Compass Netfiles Other Administrative Information CS105 Fall
Introduction to Programming Workshop 1 PHYS1101 Discovery Skills in Physics Dr. Nigel Dipper Room 125d
ENTERING ELIGIBLE ENERGY RESOURCE APPLICATIONS IN DELAFILE Version 2.0 August 25, 2015.
Online Training for TEXAS TECH UNIVERSITY and TEXAS TECH HSC Hiring Managers Employment Office April 2003.
ABI Gradebook Training We are all in this together!
Computer Programming for Biologists Oct 30 th – Dec 11 th, 2014 Karsten Hokamp  Fill out.
STRINGS CMSC 201 – Lab 3. Overview Objectives for today's lab:  Obtain experience using strings in Python, including looping over characters in strings.
Start the slide show by clicking on the "Slide Show" option in the above menu and choose "View Show”. or – hit the F5 Key.
Welcome to the Second Tutorial Welcome to the second part of this information system website tutorial! This tutorial is for church planters. If you’d like.
HTML Hyper Text Markup Language A simple introduction.
Creating and Publishing Your own web site PC Version SEAS 001 Professor Ahmadi.
Logging into the linux machines This series of view charts show how to log into the linux machines from the Windows environment. Machine name IP address.
1 ITI 1120 Lab # 1 An Introduction to the Lab Environment Contributors: G. Arbez, M. Eid, D. Inkpen, A. Williams, D. Amyot.
CPSC 217 T03 Week I Part #1: Unix and HELLO WORLD Hubert (Sathaporn) Hu.
Go to your school’s web locker site school name.schoolweblockers.com) Your user name is the first letter of your first name, the first 4.
COP3502: Introduction to Computer Science Yashas Shankar.
CMSC 104, Version 9/011 Introduction to C Topics Compilation Using the gcc Compiler The Anatomy of a C Program 104 C Programming Standards and Indentation.
ENEE150 – 0202 ANDREW GOFFIN Introduction to ENEE150.
Next Unix Topics Tuesday, 2/11 & 18/2014. Change Password (by 2/14/14) ssh to account on – faclinux.cse.ohio-state.edu – stdlinux.cse.ohio-state.edu passwd.
CMSC 104, Version 8/061L01Introduction.ppt Introduction CMSC 104 Problem Solving and Computer Programming.
CMSC 104, Lecture 011 Course Introduction CMSC 104 Problem Solving and Computer Programming Spring 2002 Section 0801, Wed 7:00-9:30pm Dr. Thomas Gaeng.
Algorithms  Problem: Write pseudocode for a program that keeps asking the user to input integers until the user enters zero, and then determines and outputs.
Unix and Samba By: IC Labs (Raj Kidambi). What is Unix?  Unix stands for UNiplexed Information and Computing System. (It was originally spelled "Unics.")
Creating Programs on UNIX This term you can create programs on UNIX or you can create programs using a C++ compiler on your PC. This set of slides steps.
Introduction to Python Lesson 1 First Program. Learning Outcomes In this lesson the student will: 1.Learn some important facts about PC’s 2.Learn how.
CMSC 1041 Introduction to C Creating your first C program.
COP3502: Introduction to Computer Science Yashas Shankar Lecture #2.
ENEE150: Discussion 1 Section 0104/0105 Please Sit Down at a Computer and Login!
Practical Kinetics Exercise 0: Getting Started Objectives: 1.Install Python and IPython Notebook 2.print “Hello World!”
CSx 4091 – Python Programming Spring 2013 Lecture L2 – Introduction to Python Page 1 Help: To get help, type in the following in the interpreter: Welcome.
CMSC 104, Version 1/021 Introduction CMSC 104 Problem Solving and Computer Programming Summer 2004 Section 6080 Ms. Dawn Block.
L071 Introduction to C Topics Compilation Using the gcc Compiler The Anatomy of a C Program Reading Sections
Part 1 Learning Objectives To understand that variables are a temporary named location to store data and that programmers work with different data types.
Introduction to C Topics Compilation Using the gcc Compiler
Development Environment
UMBC CMSC 104 – Section 01, Fall 2016
CS1010: Intro Workshop.
Lab Introduction Installing Python
Algorithms Problem: Write pseudocode for a program that keeps asking the user to input integers until the user enters zero, and then determines and outputs.
Introduction to Programming the WWW I
Creating Programs on UNIX
Introduction to C Topics Compilation Using the gcc Compiler
INSTALLING AND SETTING UP APACHE2 IN A LINUX ENVIRONMENT
CS190/295 Programming in Python for Life Sciences: Lecture 1
Introduction to Algorithm Design
Creating your first C program
Logging into the linux machines
Introduction to C Topics Compilation Using the gcc Compiler
Presentation transcript:

Lab III – Linux at UMBC

Overview Hello, and welcome to CMSC 201. We will be covering the following topics in this week's lab: TA Introduction: My name. My email address. My office location and office hours. The Linux/Unix Environment. Exercises: Unix Commands. Setup CMSC 201 directories Logging Out. How to logout/lock your workstation.

Switching to Python 3.0 You only need to do this once After you’ve logged into gl: Type “emacs .cshrc” This will open a file with roughly 30 lines of code, scroll to the bottom and ADD this line on the bottom of the file on it’s OWN separate line: source /afs/umbc.edu/common/etc/python33.cshrc Save and exit Log out of gl Log back in and type “python --version” Your version should now be 3.3.2

Why Python? Very simple, but powerful high level programming language Great for beginners Wide variety of applications including ‘throw away’/ad- hoc programming, scripting, web scripting, XML processing, and many more Far less code when compared to C, Java, etc. Very human readable code

Overview If you are on a lab computer, you should always be booted into Linux; otherwise, restart. You may bring your own laptop to complete your labs. However, it is your responsibility to be familiar with logging into GL and completing the lab. If you are using a Mac, simply open the Terminal: Launchpad  Utilities

General Information What good is a TA in this course ? Contact Information - Now a Blackboard Tab on the Left How are the weekly labs graded ? Complete: 3 Not Even Close: 1 Incomplete: 2 Absent: 0

Linux/Unix There are several flavors of Unix : IRIX, Solaris, Linux, etc. For this class your programs must run on the gl.umbc.edu machines which run linux. If you are in the lab and are running linux, when you log into your account you will be running linux on your own local workstation. The version of linux running in the labs is exactly the same as the one running on the gl machines. If you are logging in from another computer that's running linux, like your laptop, when you ssh into gl.umbc.edu you will be logged onto one of three machines linux1.gl.umbc.edu, linux2.gl.umbc.edu, or linux3.gl.umbc.edu depending on the load of each machine. Your directory, where all of your files are stored, can be accessed by all of the UMBC lab machines as well as by linux1, linux2 and linux3. All of the work for this class should be done within your UMBC account.

Resources Basic Unix Commands: http://www.csee.umbc.edu/courses/201/spring12/labs/u nixcmds.html Alphabetical Listing of Linux Commands: http://www.oreillynet.com/linux/cmd/ (You would do well to memorize a few, it will make your life much easier for the duration of this course)

Unix/Linux Commands As described in the previous slide, you may run linux on your local workstation or log onto gl.umbc.edu. For today's lab we're going to login as you would from home. You'll have to use the ssh command to log into gl.umbc.edu. Right-click on the desktop background to open a terminal. At the linux shell, type ssh gl.umbc.edu. Then type your password to login.

Unix/Linux Commands ‘cd’ into your 201 directory Create a ‘Labs’ directory using ‘mkdir’ folder and ‘cd’ into it Create directories for labs 3 through 14 ‘cd’ into your lab3 directory

lab3.py Today, you will create a simple program that combines the use of integers, math operators, and input/output. Start by creating the lab by typing “emacs lab3.py” which will open up the text editor and a blank file Copy the code on the next page, fill in the header with your name, section number, etc. Notice the comments found below main; use them to give you an idea of how to write your program!

lab3.py Copy the following code into your newly created file: # File: lab3.py # Written by: YOUR NAME HERE # Date: DATE HERE # Section: ? # Email: ?@umbc.edu # Description: Lab 3, i/o and Math operators def main(): #Prompt for 3 input values #Casting each input values as integers #Perform mathematical operations #Print the totals main()

lab3.py Use the EXACT header example you are given for this lab for all subsequent labs and homework! Your objective in this lab is to create a simple program that prompts the user for three separate values: Upon receiving those values, the values will be stored by default as strings; cast them into integers On the first inputted value, take that value and square it (hint: use the ‘**’ operator) For the second and third values, simply store their sums Finally, print out the values, accompanied by appropriate messages saying what operations were preformed on each value

Sample Output

To Receive a Full Lab Grade Say the name of your TA, his/her office hours, and where his/her office hours are located “Lab3.py” should output the first value entered by the user squared, and the sum of the second and third entered values Demonstrate that you are running the correct version of Python (3.3.2) via the command “python -- version”