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
RisingWave Labs, Inc. Contributor License Agreement | |
Thank you for your interest in the open source project(s) managed by RisingWave Labs, Inc. (“RisingWave Labs”). In order to clarify the intellectual property license granted with Contributions from any person or entity, RisingWave Labs must have a Contributor License Agreement (“CLA”) on file that has been signed by each contributor, indicating agreement to the license terms below. This license is for your protection as a contributor as well as the protection of RisingWave Labs and its other contributors and users; it does not change your rights to use your own Contributions for any other purpose. | |
By clicking “Accept” on this page You accept and agree to these terms and conditions for Your present and future Contributions submitted to RisingWave Labs. In return, RisingWave Labs shall consider Your Contributions for addition to the official RisingWave Labs open source project(s) for which they were submitted. Except for the license granted herein to RisingW |
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] | |
name = "my_benchmark" | |
version = "0.1.0" | |
edition = "2021" | |
[dev-dependencies] | |
criterion = { version = "0.3", features = ["async_futures"]} | |
[[bench]] | |
name = "my_benchmark" |
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
function fppc { fpp -c 'echo -n $F | pbcopy' } |
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 ( | |
"bytes" | |
"fmt" | |
"regexp" | |
"runtime/debug" | |
) | |
func f() { |
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 asyncio | |
import janus | |
import threading | |
loop = asyncio.get_event_loop() | |
q = janus.Queue(loop=loop) | |
class EventLoopThread(threading.Thread): | |
def run(self): |
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 PropertyDescriptor(): | |
def __init__(self, getmethod): | |
self.getmethod = getmethod | |
def __get__(self, obj, cls=None): | |
return self.getmethod(obj) | |
def my_property(f): | |
return PropertyDescriptor(f) |
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
const url = require('url'); | |
const puppeteer = require('puppeteer'); | |
const promisify = require('util').promisify; | |
const fs = require('fs'); | |
const inquirer = require('inquirer'); | |
const sleep = promisify(setTimeout); | |
const readFile = promisify(fs.readFile); | |
class TALearnHelper { |
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
/* | |
You can feel free to modify the exsisting codes. | |
You should ensure all functions (or classes) will be submitted are in global | |
scope. | |
If you have any question, you can ask in our course wechat group. | |
*/ |
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
<html xmlns="http://www.w3.org/1999/xhtml"><!--<!DOCTYPE HTML>--><head> | |
<meta http-equiv="Content-Type" content="text/html; charset=gb2312"> | |
<meta http-equiv="X-UA-Compatible" content="IE=5"> | |
<meta http-equiv="Expires" content="0"> | |
<meta http-equiv="Cache-Control" content="no-cache"> | |
<meta http-equiv="Pragma" content="no-cache"> | |
<link type="text/css" href="styles/gbp/datepicker.css" rel="StyleSheet"> | |
<script type="text/javascript" src="components/jquery/jquery-1.6.2.js"></script> |
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
def fib_recursive_squaring(n): | |
def __multi(f1, g1, h1, f2, g2, h2): | |
return f1 * f2 + g1 * g2, f1 * g2 + g1 * h2, g1 * g2 + h1 * h2 | |
def __fib(n): | |
if n == 1: | |
return 0, 1, 1 | |
f, g, h = __fib(int(n / 2)) | |
t1, t2, t3 = __multi(f, g, h, f, g, h) |