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 <GLFW/glfw3.h> | |
#include <stdlib.h> | |
#include <stdio.h> | |
#include <iostream> | |
using namespace std; | |
static void error_callback(int error, const char* description) | |
{ | |
fputs(description, stderr); |
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
brew reinstall openssl gettext readline sqlite3 xz zlib tcl-tk |
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
trying https://github.com/obukhov/redis-inventory first | |
install go 1.15 | |
https://www.5gfundamental.com/2021/04/install-go-lang-latest-version-1155-in.html | |
git clone https://github.com/obukhov/redis-inventory | |
sudo wget https://golang.org/dl/go1.15.5.linux-amd64.tar.gz | |
sudo tar -C /usr/local -xzf go1.15.5.linux-amd64.tar.gz | |
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
# Stash the changes: This will take your current changes and stash them. | |
git reset HEAD~1 | |
# Copy code | |
git stash | |
#Switch to the desired branch: | |
git checkout [branch-name] | |
# Apply the stash to the branch: |
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
// bash, trying mkfifo to do this in c | |
// $ mkfifo image_pipe | |
#include <stdio.h> | |
#include <stdlib.h> | |
#include <sys/types.h> | |
#include <sys/time.h> | |
#include <sys/stat.h> | |
#include <fstream> | |
#include <string> |
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
<template> | |
<div class="flex justify-between"> | |
<div> | |
<label class="tw-inline-block tw-pt-2 tw-leading-tight tw-mb-1 tw-text-base mr-2">Start Date</label> | |
<input type="date" id="start_date" v-model="start_date" class="mb-4 w-32 h-8" /> | |
</div> | |
<div> | |
<label class="tw-inline-block tw-pt-2 tw-leading-tight tw-mb-1 tw-text-base mr-2">End Date</label> | |
<input type="date" id="end_date" v-model="end_date" class="mb-4 w-32 h-8" /> | |
</div> |
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
Dijkstra's algorithm is a popular algorithm used to find the shortest path between two nodes in a graph. It is a greedy algorithm that iteratively expands the frontier of visited nodes from the starting node towards the target node, while updating the cost of each node. The algorithm maintains a priority queue of nodes to visit, with the node with the lowest current cost at the front of the queue. | |
Here are the basic steps of Dijkstra's algorithm: | |
Initialize the cost of the starting node to 0, and the cost of all other nodes to infinity. | |
Add the starting node to the priority queue. | |
While the priority queue is not empty: | |
Remove the node with the lowest cost from the priority queue (call it "current"). | |
For each neighbor of "current": | |
Calculate the cost of getting to that neighbor through "current". |
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 <OpenGL/OpenGL.h> | |
#include <GLUT/GLUT.h> | |
#include <string> | |
#include <vector> | |
#include <iostream> | |
#include "glInfo.h" | |
using namespace std; |
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
/*! | |
* jQuery Cycle Plugin (with Transition Definitions) | |
* Examples and documentation at: http://jquery.malsup.com/cycle/ | |
* Copyright (c) 2007-2010 M. Alsup | |
* Version: 2.99 (12-MAR-2011) | |
* Dual licensed under the MIT and GPL licenses. | |
* http://jquery.malsup.com/license.html | |
* Requires: jQuery v1.3.2 or later | |
*/ | |
;(function($) { |
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 fs = require('fs') | |
if (process.argc < 3) { | |
console.log('Usage: node timing.js <filename>') | |
process.exit(1) | |
} | |
const sFile = process.argv[2] | |
console.log({sFile}) |
NewerOlder