Skip to content

Instantly share code, notes, and snippets.

On Court

Snowmanzzz(Zhengzhong Zhao) zzz6519003

On Court
Block or report user

Report or block zzz6519003

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View test
i;m wondering
zzz6519003 /
Created Feb 25, 2016 — forked from LoganBarnett/
Notes from the 2015 React Rally conference.
zzz6519003 / anagram.cljs
Created Nov 29, 2015 — forked from chenglou/anagram.cljs
ClojureScript anagram implementation
View anagram.cljs
; (group-by f list): call f on each item in list. The return value becomes a key
; of the resulting map, whose keys map to the list of items for which f returned
; that key.
; (vals map): returns a list of the values of the map.
(defn anagram [words] (vals (group-by sort words)))
(= (anagram ["star" "rats" "car" "arc" "stars"])
[["star" "rats"] ["car" "arc"] ["stars"]]) ; true
View gist:327b6ec15d3b304ecc9d
/* though it's not written by me.......*/
:- use_module(library(clpfd)).
sudoku([A1,A2,A3, A4,A5,A6, A7,A8,A9,
B1,B2,B3, B4,B5,B6, B7,B8,B9,
C1,C2,C3, C4,C5,C6, C7,C8,C9,
View gist:711352d96a879694f695

| No | Sadly | There is none |

| Except this, which is a poor alternative |

| There really | should be one |

View gist:e4e1d613ac3978f3b81a
-(void) addAppAsLoginItem {
NSString * appPath = [[NSBundle mainBundle] bundlePath];
// This will retrieve the path for the application
// For example, /Applications/
CFURLRef url = (__bridge CFURLRef)[NSURL fileURLWithPath:appPath];
// Create a reference to the shared file list.
// We are adding it to the current user only.
// If we want to add it all users, use
View gist:543d2995fe351841dce7
Set up databases to run AS YOUR USER ACCOUNT with:
unset TMPDIR
mysql_install_db --verbose --user=`whoami` --basedir="$(brew --prefix mysql)" --datadir=/usr/local/var/mysql --tmpdir=/tmp
To set up base tables in another folder, or use a different user to run
mysqld, view the help for mysqld_install_db:
mysql_install_db --help
and view the MySQL documentation:
zzz6519003 / gist:c247db4e382b56f1898c
Last active Aug 29, 2015
Ultrasound communication
View gist:c247db4e382b56f1898c this one's wired, i don't even know how to correctly use it...
zzz6519003 / gist:c290ad8afbfce7d67770
Last active Aug 29, 2015
View gist:c290ad8afbfce7d67770
C |
------------ |
A | |
a | |
| |
b |
------------ |
B |
View gist:078cceccdc2ffd76e482
- (void)rtPushViewController:(UIViewController *)viewController animated:(BOOL)animated{
if ([self respondsToSelector:@selector(interactivePopGestureRecognizer)]) {
UIBarButtonItem *backItem = [[UIBarButtonItem alloc] initWithTitle:@"返回" style:UIBarButtonItemStyleBordered target:self action:nil];
self.topViewController.navigationItem.backBarButtonItem = backItem;
[backItem release];
} else {
UIImage *image = [UIImage iconForNavBack];
UIImage *highlighted = [UIImage iconForNavBackSelected];
UIButton *button = [UIButton buttonWithType:UIButtonTypeCustom];
button.frame = CGRectMake(0, 0, image.size.width, 44);
You can’t perform that action at this time.