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
| class A(object): | |
| bounded_lambda = lambda x: x | |
| def __init__(self, unbounded_lambda): | |
| self.unbounded_lambda = unbound_lambda | |
| def __call__(self): | |
| print(self.bounded_lambda, self.unbounded_lambda) | |
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
| { | |
| "\u756a2B\u8def": [ | |
| "10700231", | |
| "10700230" | |
| ], | |
| "7\u8def": [ | |
| "10000700", | |
| "10000701" | |
| ], | |
| "983\u7ebf": [ |
This file has been truncated, but you can view the full file.
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
| { | |
| "10036900": { | |
| "starting_station": "\u8305\u5c97\u65b0\u6751\u603b\u7ad9", | |
| "stations": [ | |
| "\u8305\u5c97\u65b0\u6751\u603b\u7ad9", | |
| "\u8305\u5c97\u516c\u5bd3\u7ad9", | |
| "\u4e1c\u82d1\u5c0f\u533a\u7ad9", | |
| "\u6e2f\u6e7e\u5e02\u573a\u7ad9", | |
| "\u6e2f\u6e7e\u8def\u53e3\u7ad9", | |
| "\u5927\u6c99\u897f\u7ad9", |
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
| package main | |
| import ( | |
| "fmt" | |
| "os" | |
| ) | |
| type MyFile struct { | |
| MyField string | |
| *os.File |
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
| maxsum(A, B) :- | |
| maxsum_aux(A, 0, 0, B). | |
| % Kadane's algorithm | |
| maxsum_aux([Elem|Tail], F, M, ANS) :- | |
| choose_max(0, F + Elem, Fx), | |
| choose_max(M, Fx, Mx), | |
| maxsum_aux(Tail, Fx, Mx, ANS). | |
| maxsum_aux([], F, M, ANS) :- |
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 dis | |
| def item_instanate(): | |
| class Item: | |
| pass | |
| print(Item(), Item(), Item()) |
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
| package main | |
| import ( | |
| "fmt" | |
| "sync" | |
| ) | |
| func piper(left chan int, wg *sync.WaitGroup) { | |
| forRight := make(chan int, 0) |
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
| // Locality test. | |
| // | |
| // See: | |
| // http://en.wikipedia.org/wiki/Locality_of_reference#Matrix_multiplication | |
| #include <string.h> | |
| #define N 1000 | |
| int a[N][N], b[N][N], c[N][N]; |
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
| <?php | |
| // user is a subject | |
| $user = UserService::getCurrentUser(); | |
| // role creation | |
| $role = RbacService::createRole('post', [ | |
| // Permission: | |
| // | |
| // -1: Deny |
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
| 581c581 | |
| < moduleNames = [f for f in os.listdir(moduleDir) if f.endswith('gents.py') or f.endswith('search.py')] | |
| --- | |
| > moduleNames = [f for f in os.listdir(moduleDir) if f.endswith('gents.py')] | |
| 667c667 | |
| < pass | |
| --- | |
| > pass | |
| \ No newline at end of file |