Log onto a computer first then ….

Slides:



Advertisements
Similar presentations
A+nywhere 3.0 Student Training Revised 0510 Enter your log-on name here. Enter your password here. Click here or hit enter.
Advertisements

Section 1 Introduction National 4/5 VB Course. What you should know after this lesson What is a program Who writes programs Why is sequence important.
Parameter passing mechanism: pass-by-reference. The Pass-by-reference mechanism - the agreement Recall: Parameter passing mechanism = agreement between.
A Level Computing#BristolMet Session Objectives#U2 S8 MUST identify the difference between a procedure and a function SHOULD explain the need for parameters.
Main task -write me a program
Activity 1 - WBs 5 mins Go online and spend a moment trying to find out the difference between: HIGH LEVEL programming languages and LOW LEVEL programming.
1 Shawlands Academy Higher Computing Software Development Unit.
Embroidery. Computer Aided Embroidery A computer aided embroidery machine translates sketches drawn by hand or by using a computer into stitched designs.
Python Programming Introduction to programming using python.
© The McGraw-Hill Companies, 2006 Chapter 4 Implementing methods.
Fall Week 3 CSCI-141 Scott C. Johnson.  Say we want to draw the following figure ◦ How would we go about doing this?
Section 1 Introduction National 4/5 Scratch Course.
Making Python Pretty!. How to Use This Presentation… Download a copy of this presentation to your ‘Computing’ folder. Follow the code examples, and put.
I Power Higher Computing Software Development Development Languages and Environments.
The Software Development Process
Lesson 4: Equivalent Fractions  Date:  Objective: SWBAT find equivalent fractions and compare fractions  Do Now:  DON”T DO THE OPENING. NEED TO ADJUST.
If the same piece of code needs to be used several times we can use a loop – but only if those times are all together. If you need to run the same bit.
Training Guide Copy/Print. Log into Inside Augsburg.
Transcript Upload. After logging In From the Home page You can click …”View My Transcripts”
SCORE Sequence Choices to be made Once may not be enough Reuse and recycle Evaluate and improve.
Search for it on your computer
Chapter 6 Functions The Tic-Tac-Toe Game. Chapter Content In this chapter you will learn to do the following: 0 Write your own functions 0 Accept values.
Make a function This is a starter activity and should take 5 minutes [ slide 1 ] >>> def count(number): n=1 while n
CMSC201 Computer Science I for Majors Lecture 19 – Recursion
Computer Programming.
Broadcasting (Adding a new level)
Introduction to Python
Do it now activity Last lesson we used Flowol to create a solution to a problem a computer could solve. Identify what each symbol does:
CMSC201 Computer Science I for Majors Lecture 18 – Recursion
UNIT 3 – LESSON 5 Creating Functions.
Functions.
Explain what touch develop is to your students:
Do it now You will find your do it now task in your workbook – look for the start button! Thursday, 20 September 2018.
Learning to program with Logo
CMSC201 Computer Science I for Majors Lecture 16 – Recursion
Do it now – PAGE 8 You will find your do it now task in your workbook – look for the start button! Tuesday, 20 November 2018.
Do it now – PAGE 11 You will find your do it now task in your workbook – look for the start button! Wednesday, 21 November 2018.
Functions, Procedures, and Abstraction
Do it now – PAGE 11 You will find your do it now task in your workbook – look for the start button! Friday, 23 November 2018.
Creating Functions with Parameters
CMSC201 Computer Science I for Majors Lecture 19 – Recursion
Passing Parameters by value
Story time Task 5 Computer Programming Gray , Calibri 24
Do it now – PAGE 8 You will find your do it now task in your workbook – look for the start button! Wednesday, 02 January 2019.
HTML and CSS eportfolio
Do it now – PAGE 10 You will find your do it now task in your workbook – look for the start button! Tuesday, 15 January 2019.
Controls, Properties, and Procedures
What is an algorithm? Buddy Buzz Who can answer this question?
Explain what touch develop is to your students:
Explain what touch develop is to your students:
COMPUTATIONAL THINKING COMPUTATIONAL THINKING IN PROGRAMMING
Explain what touch develop is to your students:
Do it now activity Use the coloured pencils to complete the do it now activity. Stick in your book.
Friday 8th November Mr Nicholls
Do it now – PAGE 10 You will find your do it now task in your workbook – look for the start button! Sunday, 28 April 2019.
Introduction to Python
Understanding Browsers
Do it now – PAGE 8 You will find your do it now task in your workbook – look for the start button! Sunday, 19 May 2019.
Do it now activity Log onto the computer.
Do it now – PAGE 7 You will find your do it now task in your workbook – look for the start button! Sunday, 19 May 2019.
Digital footprint.
Do it now – PAGE 8 You will find your do it now task in your workbook – look for the start button! Sunday, 12 May 2019.
Do it now – PAGE 11 You will find your do it now task in your workbook – look for the start button! Monday, 20 May 2019.
Do it now You will find your do it now task in your workbook – look for the start button! Thursday, 23 May 2019.
Do it now – PAGE 3 You will find your do it now task in your workbook – look for the start button! Thursday, 23 May 2019.
Functions, Procedures, and Abstraction
CMPT 120 Lecture 15 – Unit 3 – Graphics and Animation
Game / Application Quote Brief
Programming Techniques
Introduction to Methods and Interfaces
Presentation transcript:

Log onto a computer first then …. Do it now – page 8 Log onto a computer first then …. Go back to your normal desk, find your do it now task in your workbook – look for the start button! Friday, 30 November 2018

Sub-solution using procedures

Learning Objective “Find out how a procedure can be used to hide the detail in your programs” You will find differentiated outcomes for this lesson on the front of your workbook. Friday, 30 November 2018

FACT: Programmers are Lazy! Sub-solution procedure New Learning FACT: Programmers are Lazy! Sub-solution procedure Explain that sub-solution is used to hide the detail in your programs but also to make it possible to re-use code. We will learn about one type of sub-solution today called a procedure Find out how a procedure can be used to hide the detail in your programs

New Learning square() right(70) from turtle import * def square(): forward(100) right(90) square() right(70) This is an example of a program that includes a procedure Find out how a procedure can be used to hide the detail in your programs

New Learning def square(): forward(100) right(90) here is a closer look at the procedure – you will have noticed that it has been called square and has a number of instructions built into it I will now run through the code showing you what is happening Find out how a procedure can be used to hide the detail in your programs

New Learning square() right(70) forward(100) Here is the rest of the program, you will notice that the first instruction is a call to the procedure – so control switches to the procedure Find out how a procedure can be used to hide the detail in your programs

New Learning def square(): forward(100) right(90) control is passed to the procedure that has been called and the computer executes each instruction in order inside the procedure Find out how a procedure can be used to hide the detail in your programs

New Learning def square(): forward(100) right(90) Find out how a procedure can be used to hide the detail in your programs

New Learning def square(): forward(100) right(90) Find out how a procedure can be used to hide the detail in your programs

New Learning def square(): forward(100) right(90) Find out how a procedure can be used to hide the detail in your programs

New Learning def square(): forward(100) right(90) Find out how a procedure can be used to hide the detail in your programs

New Learning def square(): forward(100) right(90) Find out how a procedure can be used to hide the detail in your programs

New Learning def square(): forward(100) right(90) Find out how a procedure can be used to hide the detail in your programs

New Learning def square(): forward(100) right(90) We have got to the end of the procedures code so control passes back to the main part of the program (or the main method) Find out how a procedure can be used to hide the detail in your programs

New Learning square() right(70) forward(100) the instructions in the main method continue to be executed in order Find out how a procedure can be used to hide the detail in your programs

New Learning square() right(70) forward(100) Find out how a procedure can be used to hide the detail in your programs

New Learning square() right(70) forward(100) once again the procedure square has been called so control is again passed to the procedure Find out how a procedure can be used to hide the detail in your programs

New Learning def square(): forward(100) right(90) This is an example of a procedure Find out how a procedure can be used to hide the detail in your programs

New Learning def square(): forward(100) right(90) This is an example of a procedure Find out how a procedure can be used to hide the detail in your programs

New Learning def square(): forward(100) right(90) This is an example of a procedure Find out how a procedure can be used to hide the detail in your programs

New Learning def square(): forward(100) right(90) This is an example of a procedure Find out how a procedure can be used to hide the detail in your programs

New Learning def square(): forward(100) right(90) This is an example of a procedure Find out how a procedure can be used to hide the detail in your programs

New Learning def square(): forward(100) right(90) This is an example of a procedure Find out how a procedure can be used to hide the detail in your programs

New Learning def square(): forward(100) right(90) This is an example of a procedure Find out how a procedure can be used to hide the detail in your programs

New Learning def square(): forward(100) right(90) This is an example of a procedure Find out how a procedure can be used to hide the detail in your programs

New Learning square() right(70) forward(100) We have reached the end of the program and so the computer stops working. Here is what the actual program looks like when run inside Python Find out how a procedure can be used to hide the detail in your programs

Why should you use procedures when writing programs? Talk Task Why should you use procedures when writing programs? q1 – level 4 q2 + 3 – level 5 q4 + 5 – level 6 Find out how a procedure can be used to hide the detail in your programs

from turtle import * Using Standard libraries Learning development from turtle import * Using Standard libraries Python only has a limited number of built in methods (things it can do using single keywords like print) If you want to extend the number of choices of method you have to choose from you can use the from xxx import method at the beginning of your code. This example imports the screen turtle that I showed you in my example code Friday, 30 November 2018

Talk Task What is a library? How does using libraries improve your programming using Python? Why do you need to use functions when programming? What is the purpose of parameters? q1 – level 4 q2 + 3 – level 5 q4 + 5 – level 6 Find out how a procedure can be used to hide the detail in your programs

Independent Task Copy the code from page 9 to draw a triangle – can you adapt it so it is written as a procedure? Extend the program to use procedures to draw 3 different shapes. Upload to Edmodo once you are finished Find out how a procedure can be used to hide the detail in your programs

What is a procedure used for? Exit ticket What is a procedure used for? R A G scam Find out how a procedure can be used to hide the detail in your programs