banner



4.2 Code Practice: Question 1

Python Crook Sheet
Earsketch
Earsketch Tutorial
Online Python Compiler
Digital Textbook
Python Code Visualizer
100 Days of Code

Oct 24

Adjacent is 8.10 Writing a Elementary Sort. In this lesson, you will learn to write a uncomplicated sort and the basics of how to rearrange data in a list.

Oct 20

The Whale List

Go to Listing Items - Data Types. Copy the code below and paste it into the Try It Yourself window. And then add the code in the paradigm and run it.

name = ["whale1", "whale2", "whale3", "whale4", "whale5", "whale6", "whale7", "whale8", "whale9", "whale10", "whale11", "whale12", "whale13", "whale14", "whale15", "whale16", "whale17", "whale18", "whale19", "whale20", "whale21", "whale22", "whale23"]

ten = [-67.43928,-68.51367,-68.4956,-67.9487,-63.41219,-63.2847,-63.44392,-63.26444,-62.21766,-62.68708,-62.14266,-61.43989,-61.64667,-61.30743,-61.15596,-61.10747,-61.23049,-61.21565,-61.04606,-61.0237,-61.24702,-61.0493,-60.91662];

y = [48.83191,48.67595,48.70041,48.81702,48.64912,48.57189,48.39717,48.40019,48.3109,48.37088,48.04738,48.09392,48.02449,48.07909,48.14254,48.08245,48.34054,48.01869,48.04373,47.91508,48.18848,47.83466,47.35136];

Whale List

October 19

Nosotros proceed with viii.8 Sorting and Searching. In this lesson, we'll take some other look at algorithms and get introduced to two of the most important algorithms used in reckoner programming: searching and sorting. Later this lesson, you lot'll be prepared to write your own programs that include searching and sorting algorithms in the side by side two lessons.

What is an algorithm and why should you care?

A guessing game

Sorting

Selection Sort Pseudocode


Oct 17

We begin the week with 8.5 List Methods. In this lesson, we'll larn several of the basic methods that deal with lists in Python. Then we tin can take Quiz 8. The access lawmaking is thunder.

Oct 14

Next in Unit of measurement 8 is eight.3 Element vs Alphabetize. In this lesson, we'll look at how to populate a list with random numbers. We'll besides learn how a list index is related to list values, and we will practice using a single line of code to declare and fill, or initialize, a list.



Oct thirteen

We first Unit 8 with 8.1 What are Lists?. In this lesson, we'll learn about a new blazon of variable called a list. As nosotros'll see, lists are variables that contain more than one piece of information.


Oct eleven

We will start today with 7.half-dozen Tracing Code. In this lesson, we will look at how we tin can trace the executable steps of a programme to predict what it does, determine potential errors, and expose any limits the program has in its execution. This volition make us fifty-fifty meliorate at debugging and evaluating our code. Then we volition outset Consignment vii: Calendar . For this assignment, y'all volition create a calendar program that allows the user to enter a mean solar day, calendar month, and twelvemonth in iii carve up variables.

Oct x

We brainstorm Term 3 with 7.5 Using Several Functions. In this lesson, we'll accept a look at how several functions can exist used together. We will practice coding examples to come across how several functions can exist used together to create a desired result.

Oct half dozen

We begin today with Quiz 7. So we will commencement 7.4 Returning Values. In this lesson, we will revisit strings from before in the course, and await at a variety of functions that tin be applied to strings. We'll besides learn how Python returns values from a function.


Oct v

We will motion on to 7.1 What Are Functions?. In this lesson, we volition be learning about functions (or subprograms), and how to create them. The terms "function" and "subprogram" denote the same affair. First, we review some mutual functions we've already used to sympathise how these simplify code writing.

Oct 4

Now that you've submitted your code, it's time to reflect on your work. Reflection is an essential function of computer programming, because it allows us to look back on areas nosotros are proud of, identify areas of growth, and celebrate the work we've done. Later on reflecting on your program, you'll likely know things you want to do differently the side by side time you lot kickoff coding.
Respond the Reflection Questions by writing directly in a Google Doc. Brand certain that you upload the completed questions in the submission link so that I can grade them. The reflection questions are worth 5 points out of 20 total points for this assignment. And so we will take Test 6. The access code is radio.

Sep 29-30

Now we get to Unit 6 Assignment: Animation, you will create a complex blitheness using the simplegui module in Python. Your animation should include various components that tie in everything you've learned in this unit of measurement.
This assignment is worth 20 points. x points will be earned based on the quality of the code you lot write, 5 points volition exist earned for successfully submitting a storyboard that outlines your program for the blitheness, and five points will be earned for submitting a reflection on your piece of work.
Below, read over the assignment description and begin to imagine what your animation could portray.

5 circles
5 polygons
five line commands
2 for loops
1 global variable
This volition probably accept more than one day.

Sep 28

For the Unit 6 Consignment: Animation, yous volition create a complex animation using the simplegui module in Python. Your animation should include diverse components that tie in everything you've learned in this unit.
This assignment is worth twenty points. x points will exist earned based on the quality of the code you write, 5 points will be earned for successfully submitting a storyboard that outlines your plan for the blitheness, and 5 points will exist earned for submitting a reflection on your work.
Beneath, read over the assignment description and begin to imagine what your animation could portray.

5 circles
5 polygons
5 line commands
2 for loops
i global variable
This will probably accept more than than one twenty-four hour period.

Sep 27

Side by side nosotros take on half-dozen.8 Animation. We've all played video games, which are a perfect case of how far we've come with computer animation. Underneath all of that activity is code - lots and lots of it. To make everything work correctly, we need to start with variables. Let'due south learn more than about basic animation using Python.

Sep 26

Today we volition take Quiz 6. The access lawmaking is bagel. Then we off to Today nosotros will accept 6.seven Emojis. We see these little graphics every 24-hour interval, and take for granted how they're created. Everything we run into needs to be created by someone. In this lesson, that "someone" is you! Nosotros'll look at how to create an emoji in Python, then you lot'll create your own.

Sep 22

Now we will work with 6.6 Circles. The canvas.draw_circle() function is similar to what you've already done with the canvass.draw_polygon() and sail.draw_line() commands: it's just a different shape. You will notice these commands very helpful as you continue to work with graphics in your programs.

Sep 21

Now nosotros acquire to Draw a House. In this lesson, we're going to combine some of the drawing commands that nosotros learned earlier, and use them to create a crude sketch of a firm. After you sympathise the basics, you will take the code that Dana uses and add together new items to create a business firm of your own in this lesson's Code Practice.

Sep 20

We continue with 6.iv Lines. One of the near basic graphics that you volition come up across is a simple line. While it is a basic graphical chemical element, it'south notwithstanding a fiddling more than involved than drawing a line on a slice of paper. Where does the line first? Where does it end? What color is it? In this lesson, we'll show you how easy drawing a line can be. We volition besides do an assignment in Google Classroom.

Sep 19

We commencement the calendar week with half dozen.iii X & Y Coordinates. We've done a lot of work with data, which is the backbone of most programs. But, sometimes nosotros need to format that information into something that looks more visually highly-seasoned. Think nearly your math lessons, that use pie charts, graphs, and tables. Those visuals assist readers ameliorate understand the data they are looking at. Permit'southward encounter how Python handles some basic graphics functions.

Sep 16

We continue with 6.ii Colors and Loops. We live in a colorful globe, and now we're going to add further color to the code we write! We'll apply colour to the types of programming loops that nosotros studied already. For this Code Do, nosotros're going to jump over to an interactive Python site and learn almost repetition with images. Once you've got the hang of repeating images, upload at to the lowest degree 6 of your images to Google Classroom.

Sep fifteen

Nosotros showtime with Unit 6 (we are skipping Unit of measurement 5) with vi.one Color Code. Python isn't express to but numbers or calculations. You tin can add colors to enhance your programs and make them more interesting to your users.

Sep 13

We pick upwardly with four.nine Summing. In this lesson, we will learn about summing using a for loop.

Sep 12

We start Term two with 4.eight Counting by Other Than 1. We learned that the range function tin can take dissimilar parameters: range(x), range(x,y) and range(x,y,z). Let's look at how a for loop uses these parameters to count past numbers other than 1. Afterword, we will take Quiz 4. Access Code kiwi

Sep nine

Today we wait at a new office. 4.6 Range Function returns the sequence of the given number between the given range. The most mutual employ of information technology is to iterate sequence blazon (Python range() Listing, string, etc. ) with for and while loop using Python. Side by side, nosotros'll wait at For Loops.

Sep eight

Today nosotros look at data once again with four.4 Data Revisited and a review of looping. We've learned how to utilise diverse forms of data in previous lessons. Now, we are going to harness that data using some of the techniques we've recently learned. Before nosotros movement on to more advanced forms of loop, like the for loop, let'south pause to review what we've learned and so far. In this lesson, nosotros'll elaborate on how while loops can be used in our code and review primal vocabulary.


Sep half-dozen

Today we take Examination 3. The access code is hobby. Then it'due south on to 4.ane Loops. Sometimes, there will be actions that we demand to be performed over and again. But, copying and pasting those commands several times is not the most efficient style of doing things. If nosotros want to save time and effort, how can we streamline our code?

Sep 2

We'll do Consignment 3: Chatbot. A chatbot is a computer plan designed to emulate human chat. For this program, you will employ if statements, user input, and random numbers to create a bones chatbot.

The Scenario
You take decided to design a fashion chatbot that helps people option out their mode preferences. Your bot tin can gauge what types of clothes and accessories the user might like.

Your chatbot should inquire the user the following (minimum requirements for the grader) and and then give answers depending on the answers the user inputs:
at least 6 questions
at least three if-elif-else statements
the apply of the random module and randomly generated numbers

Sep 1

Today we have Quiz 3. The access code is cardigan. Then it's on to 3.half-dozen Defining Algorithms. We've been using algorithms for most of our lives, but never defined those activities in that way. Algorithms are just a set of steps or instructions used to solve a problem or accomplish a job. Y'all could make an algorithm out of all the activities you performed today before starting this lesson. And so, how exercise we apply algorithms to Python?


Aug 31

We continue Unit of measurement 3 with iii.4 If – Else. We know how to use the if argument - however, it can be a burden to write a separate if statement when nosotros are only trying to write code for when the initial statement fails. In these cases, the if-else statement lets us write code for the failing scenario with ease.


Aug xxx

We get-go Unit of measurement 3 with iii.2 Simple Ifs. What happens when you use the "if" statement in your code? "If" acts as a gateway to further deportment. If something is truthful, then the plan does something. If information technology's not truthful, then it skips over that office and moves on in the program.


Aug 29

We start the week with Assignment ii: Room Area. For this lab, yous will find the area of an irregularly shaped room with the shape as shown above. Inquire the user to enter the values for sides A, B, C, D, and Eastward and print out the total room area. Remember the formula for finding the area of a rectangle is length * width and the expanse of a right triangle is 0.v * the base of operations * meridian. Please notation the final area should be in decimal format.

Aug 26

We are going to talk about ii.half dozen Big Data. Big Information are sets of information that are so large or complex that traditional data processing (calculators, spreadsheets) aren't capable of dealing with them. But, with the advances in retentiveness and processing power, we can quickly turn this information into valuable resources for u.s.a. to use.

Aug 25

Today we larn almost random numbers. Generating Random Numbers is a lot like rolling dice. Every time you curlicue, you tin can get a different number between 1 and 6. In Python, you're not limited to a fixed prepare of numbers. And with the random module that nosotros'll look at in this lesson, you lot're not limited to numbers at all, just can use other values as well. Then we will take Quiz 2. The access code is tomato plant.

Aug 24

We'll finish upwards with 2.3 Code Exercise, and so move on to 2.4 Congenital-in Functions. Generating random numbers is a lot like rolling dice. Every time yous roll, you tin get a dissimilar number between 1 and 6. In Python, yous're not limited to a fixed prepare of numbers. And with the random module that nosotros'll look at in this lesson, you lot're non limited to numbers at all, but tin can use other values as well.


Aug 23

Today nosotros learn a new kind of partitioning. two.3 Modular Sectionalisation . In this lesson, we'll learn a new mode to exercise division, that focuses on the residuum after ii numbers are divided. We'll showtime with a few examples of how we apply modular division and explain why we should intendance near remainders.

Aug 22

Today we python into a figurer. 2.2 Basic Calculations . In this lesson, we will larn how Python handles number calculations, the rules for basic operations, how parentheses are used in Python, how to employ exponents, and the order of operations.

Aug 19

Today nosotros volition have Test i. Access Code salmon
After the test, we will jump to 2.1 Computer History. In this lesson, we will larn near the history of computers and explore how technology has evolved over time.

Aug eighteen

We move on to 1.9 Understanding Binary. For many of your classes, you lot may store information by writing notes into a notebook. But, how does a estimator shop information it receives? In this lesson, we'll explore binary code, the system that computers use to store data. Then we will bound to Consignment 1: Empty-headed Sentences. We'll write a plan that will ask the user for a series of words. Then plug them into our paragraph template. Write a program that will enquire the user for a series of words. And then plug them into our paragraph template.

Aug 17

We keep with 1.viii Analog vs. Digital. In this lesson, nosotros will expect at data and how computers procedure the data we input.

Aug xvi

We will start with i.7 Information Types and Variables. You may have heard the word variable in a math class before. In this lesson, we will acquire how Python handles dissimilar types of information and variables, and how it stores that data.

Aug 15

We move on to 1.6 Input. In the previous lesson, we learned almost data computers ship out to the user. In this lesson, we volition learn well-nigh the information that users transport into the computer. Nosotros'll also study variables and how they're used in Python.

Aug 12

We will end the week with 1.5 Output There will be some videos, a lesson exercise (quiz), and and then Code Practice.


Aug xi

Nosotros will go on with ane.4 Hardware and Software There volition be some videos, a lesson do (quiz), and and so we'll jump to 1.4 Code Do: Question 1.


Aug 10

Nosotros will brainstorm with 1.i What is Figurer Science? There will be some videos, a lesson practise (quiz), and then we'll practice the lawmaking practise.


Aug 9

Sign in to your online accounts

Become to Project STEM sign upward with your schoolhouse email account. Then join our form, form lawmaking 0541fd

And so, go to Google Classroom and bring together class cyhfg2s

I don't know how much we volition use Classroom, but nosotros'll set it upward just in instance.

I likewise want y'all to create a document in your Google drive named Python Notes. From time to fourth dimension I'll ask you to add to it.

Adjacent get to Welcome to the course.

Then, we'll look at a short video called Code Stars.

CS Python Fundamentals is an introductory-level form for students brand new to programming and reckoner science. In this class, y'all volition learn problem-solving strategies, software pattern, and the foundations of figurer science. You'll do so using two primal tools: the Project Stem programming environs and EarSketch, a software package that turns your code into music.

Non only will this course prepare you for continuing your studies in computer science (for instance, by taking AP Informatics A and AP Computer Science Principles), but it will as well teach you lot how to think like a scientist and solve real-earth problems, skills that are important to every 21st-century citizen.

There are no prerequisites for this course, although y'all should have bones familiarity with how to operate a figurer and use applications. It's also recommended that you take familiarity with basic algebra principles before starting this course.

Click hither for the course syllabus.

Creative Commons License
This work is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License.

4.2 Code Practice: Question 1,

Source: https://im8x10.com/bowman/introAssignments.html

Posted by: parkerselday.blogspot.com

0 Response to "4.2 Code Practice: Question 1"

Post a Comment

Iklan Atas Artikel

Iklan Tengah Artikel 1

Iklan Tengah Artikel 2

Iklan Bawah Artikel