| // To compile with gcc: (tested on Ubuntu 14.04 64bit): | |
| // g++ sdl2_opengl.cpp -lSDL2 -lGL | |
| // To compile with msvc: (tested on Windows 7 64bit) | |
| // cl sdl2_opengl.cpp /I C:\sdl2path\include /link C:\path\SDL2.lib C:\path\SDL2main.lib /SUBSYSTEM:CONSOLE /NODEFAULTLIB:libcmtd.lib opengl32.lib | |
| #include <stdio.h> | |
| #include <stdint.h> | |
| #include <assert.h> | |
| #include <SDL2/SDL.h> | |
| #include <SDL2/SDL_opengl.h> |
| const I = x => x | |
| const K = x => y => x | |
| const A = f => x => f (x) | |
| const T = x => f => f (x) | |
| const W = f => x => f (x) (x) | |
| const C = f => y => x => f (x) (y) | |
| const B = f => g => x => f (g (x)) | |
| const S = f => g => x => f (x) (g (x)) | |
| const S_ = f => g => x => f (g (x)) (x) | |
| const S2 = f => g => h => x => f (g (x)) (h (x)) |
| extension UITextField { | |
| func underlined(){ | |
| let border = CALayer() | |
| let width = CGFloat(1.0) | |
| border.borderColor = UIColor.lightGrayColor().CGColor | |
| border.frame = CGRect(x: 0, y: self.frame.size.height - width, width: self.frame.size.width, height: self.frame.size.height) | |
| border.borderWidth = width | |
| self.layer.addSublayer(border) | |
| self.layer.masksToBounds = true |
| #!/usr/bin/env ruby -rubygems | |
| # Shamir's Secret Sharing Scheme with m-of-n rule for 128-bit numbers. | |
| # Author: Oleg Andreev <oleganza@gmail.com> | |
| # | |
| # * Deterministic, extensible algorithm: every combination of secret and threshold produces exactly the same shares on each run. More shares can be generated without invalidating the first ones. | |
| # * This algorithm splits and restores 128-bit secrets with up to 16 shares and up to 16 shares threshold. | |
| # * Secret is a binary 16-byte string below ffffffffffffffffffffffffffffff61. | |
| # * Shares are 17-byte binary strings with first byte indicating threshold and share index (these are necessary for recovery). | |
| # | |
| # See also: https://en.wikipedia.org/wiki/Shamir%27s_Secret_Sharing |
| #include <stdio.h> | |
| #include <stdlib.h> | |
| #include <string.h> | |
| #include <dlfcn.h> | |
| int main(int argc, char** argv) | |
| { | |
| void *handle; | |
| void (*func_print_name)(const char*); |
| Adding Hidden Agendas | |
| Adjusting Bell Curves | |
| Aesthesizing Industrial Areas | |
| Aligning Covariance Matrices | |
| Applying Feng Shui Shaders | |
| Applying Theatre Soda Layer | |
| Asserting Packed Exemplars | |
| Attempting to Lock Back-Buffer | |
| Binding Sapling Root System | |
| Breeding Fauna |
04/26/2103. From a lecture by Professor John Ousterhout at Stanford, class CS142.
This is my most touchy-feely thought for the weekend. Here’s the basic idea: It’s really hard to build relationships that last for a long time. If you haven’t discovered this, you will discover this sooner or later. And it's hard both for personal relationships and for business relationships. And to me, it's pretty amazing that two people can stay married for 25 years without killing each other.
[Laughter]
> But honestly, most professional relationships don't last anywhere near that long. The best bands always seem to break up after 2 or 3 years. And business partnerships fall apart, and there's all these problems in these relationships that just don't last. So, why is that? Well, in my view, it’s relationships don't fail because there some single catastrophic event to destroy them, although often there is a single catastrophic event around the the end of the relation
| 2015-10-24 | |
| - Changed comment | |
| - Walk though returning form to wrap. Racket still doesn't work. | |
| - Fixed incorrect example on definition of macro and usage environment. | |
| Comment of: https://twitter.com/anohana/status/657865512370634753 |
This information applies to the PICO-8 0.1.6 release.
This document is here to help folks with a proficiency in Lua understand the limitations and discrepencies between Lua and PICO-8's Lua.
You can always view the manual or yellowafterlife's extended 0.1.1 manual.
- anything written in uppercase the PICO-8 editor or .p8 is made lowercase by the editor. → editing the .p8 file directly can work
print(function() end)outputs the stringfunctioninstead of the stringfunction: 0x0000000.