# ---
# jupyter:
#   jupytext:
#     text_representation:
#       extension: .py
#       format_name: light
#       format_version: '1.5'
#       jupytext_version: 1.14.4
#   kernelspec:
#     display_name: Python 2
#     language: python
#     name: python2
# ---

# # Circles and Spheres
#
# ![Minecraft Circles and Spheres](http://www.minecraftdl.com/wp-content/uploads/2013/10/Dual-Sphere-Survival-Map.png)
#
# In our first class we learned about functions. A function is a task to do something. Some of the functions we used are **mc.postToChat** to post a message to Minecraft and **time.sleep** to pause our program execution for 1 second. In today's adventure, we learn more about functions. We will use new functions to build circles and spheres in Minecraft.
#
#

# ## Functions and arguments
# In our previous class we were introduced to functions. Sometimes you need more than just a task name to complete a task.  
#
# E.g., "Practice you writing!", is not enough, you want to know for how long. "Practice your writing for 15 minutes!" is more helpful.
#
# If we had a function for the "practice writing" task, we would write is as,
#
# ```python
# practiceWriting(15)
# ```
#
# the additional pieces information we pass to a function are called its arguments. A function can have zero or more arguments just like a real tasks need zero or more pieces of information to complete them. Both the functions that you used so far needed arguments. For the function examples below,
#
# ```python
# mc.postToChat("Hi Kids")
# time.sleep(1)
# ```
#
# The **mc.postToChat** function needs the argument _"<NAME>"_ which is the message to post to the Minecraft chat window. The **time.sleep** function needs the argument _1_ which is the number of seconds to pause the program from running.

# ## Building functions
#
# The first building function **drawings.drawMyCircle** uses two arguments - the radius of the circle to build and the block id to use for building the circle. 
#
# ```python
# drawings.drawMyCircle(radius,blockId)
# # e.g., drawings.drawMyCircle(5,block.STONE.id)
# ```
#
# The second building function **drawings.drawMySphere** uses two arguments - the radius of the sphere to build and the block id to use for building the sphere. 
#
# ```python
# drawings.drawMySphere(radius,blockId)
# # e.g., drawings.drawMySphere(5,block.STONE.id)
# ```
#
# In the following tasks, you will use these functions with different arguments to build circles and spheres in Minecraft. 
#
# **Note:** Before you start your tasks, **start Minecraft** and run the program cell below to make the building functions available to your programs.

import sys
sys.path.append('/home/pi/minecraft-programming')
import mcpi.block as block
import time
import drawings

# ## Task 1
# Use the building functions to build three circles with radii 5, 9 and 13 in the same position (center).

# Task 1 program


# ## Task 2
# Use the building functions to build three spheres of radius 5, 9 and 13 in three different positions.

# Task 2 program


# ## Task 3
#
# Write a program to build a sphere of radius 5 at the center, a circle of radius 8 and a circle of radius 13 at Steve's current position

# Task 3 program


# ## Task 4
# Use a new function **drawings.drawMyHollowSphere**. The function takes two arguments. First the **radius** of the hollow sphere to build and second, the **blockId** to use for building the hollow sphere.

# Task 4 program


StarcoderdataJupyterScriptsDedupFiltered