76 karma · joined July 21, 2011
In short, we’ll trade you iCloud for something great.
Love this subtle dig at iCloud.The source is at https://github.com/bridger/optic-workbench
A bit of explanation (and a link to the pre-built binary) is at http://www.bridgermaxwell.com/index.php/blog/optic-workbench....
(Sorry it is only for Macs. I would love to redo it in Javascript someday, once I know Javascript.)
(define (multiply number1 number2)
(lambda (f)
(number1 (lambda (x) ((number2 f) x)))))
(define (exponentiate base exponent)
(exponent base))That said, I quickly had to come up with a better name than Soylent. I call mine Science (for human consumption). It makes it distinct from food. "Did you get lunch?" "No, I just had Science today."
Scratch and Quartz composer show code in a graphical way. Are there examples of languages that show the data path in a similarly graphical way?
I would love to see how variables relate to each other and other functions (the data path) separated from the order in which these operations actually happen (the controller). It would be an interesting way to debug. For example, variables that get assignment but are never read would be glaringly obvious.
It should be on the App Store soon (awaiting Apple's approval!). If you are interested in trying it, send me an email. bridger@understudyapp.com
One advantage is that it makes sure things are pixel-integral, no matter the scale factor of the screen. For example, his code example,
button.x = self.view.width * 0.2; // Position the inset at 20% of the width.
has a pretty good chance at starting the button at x=21.845, or some other point in-between pixels and producing a blurry line. If you do this same relation in Auto Layout, the engine makes sure that the positions and widths are all pixel-integral.
This is not as simple as just rounding everything, either! For example, if you have two views
[blue][red], you want to make sure you round their shared edge either to the left or to the right. Otherwise, there will be a gap between them. You need to make sure you round their shared edge the same way consistently too, or it will jump back and forth as you resize a window and produce a noticeable jitter.
Also, in that same code example, they set a button's x position to be directly related to the width of a view. If you ever want to support RTL interfaces, this is a bad idea. It is relating a width to a position. In a RTL interface, the correct code would be
button.x = self.view.width - self.view.width * 0.2 - button.width
Complicated! In general, you shouldn't convert between positions and sizes. Instead, I would make an invisible spacer view and lay them out like this using the layout format language
|[spacerView][button]
Then make a relation setting the spacerView's width to be 0.2 of the superview's width. This will produce constraints that correctly work in a RTL interface, laying it out like [button][spacerView]|.
If anyone is interested in reading SICP now, you should try out my app. We find you someone and you have a good conversation about the material each week through video chat and a whiteboard. We aren't launched yet, but you can check out our simple demo (https://www.youtube.com/watch?v=DlUTKzrqECE) and send me an email if you want to try the beta. bridger@understudyapp.com
One of my favorite parts of math is puzzling over problems and coming up with solutions myself (even if the solution has been known for thousands of years prior.) I wish this book would set up problems I could puzzle over, rather than just give me the solutions before I knew there was a problem!
The book I am reading (Journey Through Genius) is really good, but not very advanced math. I would love to find some self-study math courses that approach math not as a bunch of symbol-pushing but as an art with a history.