Make App Pie

Training for Developers and Artists

Kinderswift 8 Challenge Answers

Watch the video for any commentary. Here are two answers. There a lot of possible ones.

Answer 1

func blueColor(blueVal:Int) -> UIColor {
let color = CGFloat(CGFloat(blueVal) / 255.0)
return UIColor(red: 0.0, green: 0.0, blue: color, alpha: 1.0)


Answer 2

//necessary code to run the answer
func pizzaArea(z:Double) ->Double {
//area of pizza : pi * z * z = a
    let pi = 3.14159265358
    return pi * z * z

func deepDishVolume(diameter:Double,height:Double){
    let radius = diameter * 0.5
    let area = pizzaArea(radius)
    let volume = area * height

deepDishVolume(13, 2)

One response to “Kinderswift 8 Challenge Answers”

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.

%d bloggers like this: