Example playground to show off the visualzations you can get with Swift playgrounds.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Playground - noun: a place where people can play | |
import UIKit | |
import QuartzCore | |
var str = "Hello, playground" | |
var nums = [1, 3, 5, 7, 9, 11, 13] | |
var count = 1 | |
for num in nums { | |
count *= num | |
} | |
var view = UIView(frame: CGRectMake(0, 0, 100, 100)) | |
view.layer.cornerRadius = 10.0 | |
view.layer.borderColor = UIColor.blueColor().CGColor | |
view.layer.borderWidth = 10.0 | |
var miniView = UIView(frame: CGRectMake(30, 30, 40, 40)) | |
miniView.backgroundColor = UIColor.greenColor() | |
view.addSubview(miniView) | |
view.backgroundColor = UIColor.yellowColor() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment