brew install basictex --cask
eval "$(/usr/libexec/path_helper)"
pandoc whitepaper.md -o a.pdf \
--pdf-engine=xelatex \
-V mainfont="Arial" \
-V geometry:margin=1in
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
| // SPDX-License-Identifier: MIT | |
| pragma solidity ^0.8.20; | |
| import {FunctionsClient} from "@chainlink/contracts@1.5.0/src/v0.8/functions/v1_0_0/FunctionsClient.sol"; | |
| import {FunctionsRequest} from "@chainlink/contracts@1.5.0/src/v0.8/functions/v1_0_0/libraries/FunctionsRequest.sol"; | |
| import {ConfirmedOwner} from "@chainlink/contracts@1.5.0/src/v0.8/shared/access/ConfirmedOwner.sol"; | |
| /** | |
| * Request testnet LINK and ETH here: https://faucets.chain.link/ | |
| * Find information on LINK Token Contracts and get the latest ETH and LINK faucets here: |
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 Tensor: | |
| def __init__(self, data): | |
| self.data = data | |
| self.shape = self.get_shape(data) | |
| def get_shape(self, data): | |
| if isinstance(data, list): # check if data is a list | |
| return (len(data),) + self.get_shape(data[0]) # calculate shape recursively | |
| else: | |
| return () # return empty tuple |
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 random | |
| class Module: | |
| def zero_grad(self): | |
| for p in self.parameters(): | |
| p.grad = 0 | |
| def parameters(self): | |
| return [] |
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
| #include <stdio.h> | |
| #include <string.h> | |
| #include <stdlib.h> | |
| #define NUM_REGS 4 | |
| #define MAX_LINE 100 | |
| #define WIDTH 10 | |
| #define HEIGHT 10 | |
| int registers[NUM_REGS]; |
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
| #include <iostream> | |
| #include <string> | |
| #include <regex> | |
| #include <vector> | |
| #include <memory> | |
| // ---------------- Token Definitions ---------------- | |
| enum class TokenType { | |
| NUMBER, IDENTIFIER, ASSIGN, PLUS, MINUS, MULT, DIV, LPAREN, RPAREN, DOT, EOF_TOKEN | |
| }; |
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
| ffmpeg -i IMG_1493.mov -vf "scale=5120:-1, crop=5120:1024:(in_w-out_w)/2:(in_h-out_h)/2" -c:a copy output.mp4 |
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 "https://github.com/smartcontractkit/chainlink/blob/develop/contracts/src/v0.8/VRFConsumerBase.sol"; | |
| contract Test is VRFConsumerBase { | |
| bytes32 public keyHash; | |
| uint256 public fee; | |
| uint256 public ticketPrice; | |
| uint256 public result; | |
| // ---------------- GOERLI ADDRESSESS---------------- |
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
| ; Fast HTTP client with minimal but essential error checking | |
| ; Target: Maintain 1.3ms speed while ensuring clean exit | |
| section .data | |
| align 64 | |
| ; Optimized minimal HTTP request | |
| http_req db "GET / HTTP/1.1",13,10,"Host: localhost",13,10,13,10 | |
| req_len equ $ - http_req | |
| ; Pre-calculated sockaddr_in as 32-bit values |
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
| //gcc full.c -lcapstone -lelf -lm -lstdc++ -lkeystone -lm -lstdc++ | |
| #include <stdio.h> | |
| #include <stdlib.h> | |
| #include <fcntl.h> | |
| #include <unistd.h> | |
| #include <sys/mman.h> | |
| #include <capstone/capstone.h> | |
| #include <keystone/keystone.h> | |
| #include <elf.h> | |
| #include <string.h> |
NewerOlder