This file contains hidden or 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
| { | |
| "login": "agiletalk", | |
| "avatar_url": "https://avatars2.githubusercontent.com/u/331528?v=4", | |
| "name": "chanju Jeon", | |
| "email": null, | |
| "public_repos": 20, | |
| "public_gists": 46, | |
| "followers": 15, | |
| "following": 23 | |
| } |
This file contains hidden or 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
| protocol FeedItem: Codable { | |
| var type: FeedType { get } | |
| } | |
| enum FeedType: String, Codable { | |
| case job | |
| case company | |
| case content | |
| case event | |
| case theme |
This file contains hidden or 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
| import Foundation | |
| import UIKit | |
| // Usage Examples | |
| let shadowColor = Color.shadow.value | |
| let shadowColorWithAlpha = Color.shadow.withAlpha(0.5) | |
| let customColorWithAlpha = Color.custom(hexString: "#123edd", alpha: 0.25).value | |
| enum Color { | |
This file contains hidden or 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
| func application(application: UIApplication, didFinishLaunchingWithOptions launchOptions: [NSObject: AnyObject]?) -> Bool { | |
| // Override point for customization after application launch. | |
| let duration = 2.0 | |
| let launchScreen = UIStoryboard(name: "LaunchScreen", bundle: nil) | |
| let launchViewController = launchScreen.instantiateInitialViewController() | |
| let imageView = launchViewController?.view.viewWithTag(100) as! UIImageView | |
| imageView.image = UIImage.animatedImageNamed("win_", duration: duration) | |
| self.window?.rootViewController = launchViewController |
This file contains hidden or 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
| __author__ = 'agiletalk' | |
| from math import factorial | |
| print(eval("+".join(list(str(factorial(100)))))) | |
This file contains hidden or 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
| __author__ = 'agiletalk' | |
| from calendar import monthrange, SUNDAY | |
| print(len([(year, month) for year in range(1901, 2001) for month in range(1, 13) if monthrange(year, month)[0] is SUNDAY])) |
This file contains hidden or 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
| __author__ = 'agiletalk' | |
| print(eval("+".join(list(str(pow(2,1000)))))) |
This file contains hidden or 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
| __author__ = 'agiletalk' | |
| numbers = """ | |
| 37107287533902102798797998220837590246510135740250 | |
| 46376937677490009712648124896970078050417018260538 | |
| 74324986199524741059474233309513058123726617309629 | |
| 91942213363574161572522430563301811072406154908250 | |
| 23067588207539346171171980310421047513778063246676 | |
| 89261670696623633820136378418383684178734361726757 | |
| 28112879812849979408065481931592621691275889832738 |
This file contains hidden or 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
| -(void)touchesBegan:(NSSet *)touches withEvent:(UIEvent *)event { | |
| NSInteger current = self.selectedSegmentIndex; | |
| [super touchesBegan:touches withEvent:event]; | |
| if (current == self.selectedSegmentIndex) | |
| [self sendActionsForControlEvents:UIControlEventValueChanged]; | |
| } |