Friday 26 January 2018

Python Lesson 4 - Selection

In this lesson you are going to learn how to use 'selection' in a program.  You've used simple selection before in your Scratch Pacman program last year, eg making a blob disappear when the Pacman touched it and the score changed by 1.



Objectives and Outcomes

  • Be able to explain why selection is useful in a program (giving an example will help with this) (band 4)
  • Be able to apply this by creating a 'virtual barman' program in Python (band 5)
  • Be able to link this to an example of where you have used selection in a program last year (band 6)
Tasks
1.  Open a new blog post and title it the same as this one.

- Explain on your post why selection is useful in programming, giving an example to help your explanation.

2.  Complete the task/s set on Slide 16 of my slideshow - creating your own 'virtual barman' Python program.


Don't forget to paste screenshots to a Google doc as evidence of your work for this lesson!

3.  Complete the extension programming task on Slide 16.

4.  Link this work to Scratch programming last year to achieve band 6 - do this on your blog post.

5.  Share your Google doc correctly (Advanced - change from Private to Anyone with the link) and copy/paste link to your post, underneath your writing for Task 1.

Publish!!



Friday 19 January 2018

Python Lesson 3

In this lesson, you are going to learn how to program maths calculations in Python

Objectives and Outcomes

  • To understand that data comes in different 'types'.
  • To be able to describe a types of data (band 3)
  • To be able to explain why a computer needs to know what the data type is for a given input / variable (band 4)
  • To be able to apply this knowledge to create a program that performs arithmetic calculations (band 5)


1.  Open a new blog post and title it the same as this one.

2.  On your post, explain why we have to tell the program what type of data is being stored in a variable.  My slideshow will help you with this...


Here is the link to my slideshow that explains all of the above


Here is the link to the summary sheet (page 1) and the Maths Programming Tasks (page 2)

All programs, once run and working, need to be screenshotted and pasted to a Google doc, one after the other.

Bronze - complete Tasks 1 -3 

Silver - complete Tasks 1 - 4

Gold - complete Tasks 1 -5

Those wanting to opt for Computer Science GCSE, try to do the Extension task as well

Share Google doc (Click Advanced - change from Private to Anyone with the Link) and copy/ paste link to your blog post underneath your writing.

PUBLISH!!



Friday 12 January 2018

Python - Lesson 2

This lesson you are going to learn how to print questions and print the user's answers on the screen.  The user's answer is stored in a 'variable' (like a box) in the RAM of the computer; it's called a variable as it can change depending on who is answering the question and what they choose to answer.

Objectives and Outcomes

  • Be able to describe what a 'variable' is (band 4)
  • Be able to apply this knowledge by writing a program in Python that uses variables (band 5).
  • Be able to link this idea of variables and inputs to previous work in other programming, eg. Scratch (band 6).
1.  You will need to open a new blog post titled the same as this one.

2.  Open a tab for my blog and go to my post for this lesson.

3.  Open up the Python programming site  https://repl.it/ 

4.  Go to my slideshow for this lesson which has info and tasks...

Python Lesson 2 slideshow

5.  Read through the slideshow, completing tasks as you go.  It will tell you where and how you should evidence your work for these tasks.

6.  Complete task 1 (slide 7), task 2 (slide 8), task 3 (slide 11)

7.  Also complete task 4 (slide 11), task 5 (slide 12)

8.  Also complete task 6 (slide 14)

9.  Share your Google doc (Advanced - change form Private to Anyone with the link) and copy/paste the link to your blog post.

Publish!


Wednesday 10 January 2018

Python - Lesson 1

Objectives and Outcomes

  • Be able to explain what Python is and why it is important (band 4)
  • Be able to apply your understanding to create short programs using Python (band 5)
  • Be able to link your work today to work from previous units, eg Scratch (band 6)


Python is a programming language.  Unlike Scratch that you have used to program where the programming is done by placing 'blocks' in the correct sequence (order), Python is text-based programming ie the sort of programming that goes on behind the 'blocks'.  It is a general purpose programming language created in the late 1980s.  It is used by thousands of people to do things from testing microchips at Intel, to powering Instagram, to building video games with the PyGame library.

The written instructions will only work if they are in the correct order, correctly spelt, correctly lined up on the page and have the correct punctuation symbols.  All of this is called 'syntax' and makes it just like any language where it will only make sense if the words are in the correct order in the sentence for that language, and punctuation and spelling are correct.

Open a new blog post and title it the same as this one.

On the post, explain what the words 'sequence' and 'syntax' mean.



If you are using a Chromebook, you will need to go to this link.....
https://repl.it/     and search for Python 3.

If you are on desktop PCs, there should be a link to this in the Comp Sci folder in 'Start' menu.

Now you need to go to my worksheet with screenshots and tasks for this lesson.....

Link to Python Worksheet - Lesson 1

Follow the instructions and tasks on the worksheet.

Bronze - Task 1

Silver - Tasks 1 & 2

Gold - Tasks 1, 2 and 3

To achieve Band 6, you will also need to link this work to work you did in Scratch.  Describe, in detail, similarities and differences between the two.

Once you have completed all the tasks you can in the lesson time, share your Google doc (Advanced - change from Private to Anyone with the Link - copy/paste the link to your post).
Publish!