This file contains 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
#lang racket/base | |
;; Naive factorial | |
;; Keep stack for all recursion levels | |
;; Can do arbitrary processing at each level | |
(define (naive-fact n) | |
(if (<= n 0) | |
1 | |
(* n (naive-fact (- n 1))))) |
This file contains 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 <godot_cpp/classes/audio_frame.hpp> | |
namespace godot { | |
AudioFrame operator*(const AudioFrame & frame, double scalar) { | |
return AudioFrame{ frame.left * scalar, frame.right * scalar }; | |
} | |
AudioFrame operator*(double scalar, const AudioFrame & frame) { | |
return AudioFrame{ frame.left * scalar, frame.right * scalar }; | |
} |
This file contains 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 <deque> | |
#include <iostream> | |
#include <map> | |
#include <unordered_map> | |
#include <vector> | |
using namespace std; | |
bool shortestPathBFS(const vector<vector<int>> &graph, int start, int goal) { |
This file contains 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 <deque> | |
#include <iostream> | |
#include <map> | |
#include <unordered_map> | |
#include <vector> | |
using namespace std; | |
void printBFS(const vector<vector<int>> &graph, int start) { |
This file contains 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
"""""""""""""""""""""""""""""""""""""""" | |
" KidRigger's NVIM Configuration | |
"""""""""""""""""""""""""""""""""""""""" | |
"""""""""""""""""""""""""""""""""""""""" | |
" Setting up Vim Plug | |
"""""""""""""""""""""""""""""""""""""""" | |
call plug#begin('~/.local/share/nvim/plugged') |
This file contains 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 os | |
from sys import argv | |
import subprocess | |
name, filename, prefix, changeto = argv | |
renamer_buffer = 'RENAMER_BUFFER_314159265358979' | |
with open(renamer_buffer,'w') as fle: | |
subprocess.call(['otool','-L',filename],stdout=fle) |
This file contains 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 <algorithm> | |
#include <iostream> | |
#include <map> | |
#include <vector> | |
using namespace std; | |
#pragma region | |
void print(vector<int> v) { | |
cout << "vector: "; |
This file contains 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 "glad/glad.h" | |
#include "GLFW/glfw3.h" | |
int main() { | |
GLFWwindow* window = nullptr; | |
const int WIDTH = 1920; | |
const int HEIGHT = 1080; |
This file contains 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
# OSX | |
--enable-shared --enable-version3 --disable-programs \ | |
--enable-libmp3lame --enable-libtheora \ | |
--enable-libvorbis --enable-libvpx --enable-libwebp \ | |
--enable-opencl --enable-opengl --disable-debug \ | |
--prefix=<path-to-videodecoder-folder>/godot-videodecoder/test/addons/bin/osx | |
# Linux | |
--enable-shared --enable-version3 --disable-programs \ | |
--enable-libmp3lame --enable-libtheora \ |
This file contains 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> | |
/////////////////////////////////////////////////////////////////////////////////////////////////// | |
#ifdef P1 | |
void Foo() { std::cout << "Hello World" << std::endl; } | |
int main() { |
NewerOlder