Skip to content

Instantly share code, notes, and snippets.

@BrentAureli
BrentAureli / Compare.java
Last active September 13, 2024 04:11
Exclusive and Inclusive compares when using quotes.
import java.util.ArrayList;
import java.util.Arrays;
import java.util.List;
public class StringMatcher {
public static List<String> matchInput(String input, List<String> stringList) {
List<String> matches = new ArrayList<>();
// Check if input is surrounded by quotes
var x = 10
var y = 10
function setup() {
frameRate(1)
createCanvas(200, 200)
for(var i = 0; i < 10; i++)
setTimeout(addRect, 5000)
}
function addRect(){
function drawGrid(){
for (var i = 0; i < cols; i++) {
for (var j = 0; j < rows; j++) {
grid[i][j].draw() //grid is a 2D array of nodes
}
}
}
//inside node class
draw(){
function search(node, trace){
var arr = trace;
if(!found){
if(node == null) return;
if(node.y == 7 && node.x == 8){
found = true;
traceRoute = trace;
node.setActive(true)
}
function search(node){
if(node == null) return;
node.setActive(true)
for(var i = 0; i < node.links.length; i++){
if(node.links[i].active == false){
drawGrid()
setTimeout(search(node.links[i]), 50)
}
}
}
{
"id": "421b91639382f6be8886dd4bcff5db3e3821b64b2f6548f0a3db4bb168211c18",
"listing": {
"method": "psapi",
"indexed": "2018-06-18T12:09:49Z",
"stash": {
"name": "SELLING!",
"x": 3,
"y": 11
},
router.get('/testAPI', function(req, res, next){
//if there is a access token, proceed with bearer auth
if(req.query.access_token) next();
//skips this router stack
else next('route');
}, passport.authenticate('bearer', { session: false }),
function(req, res, next){
res.json({ SecretData: 'abc123', Authenticated: true })
});
set = function(req, res) {
res.cookie('login_token', +new Date(), { maxAge: 3600000, path: '/' });
res.redirect('/');
};
var fs = require('fs'),
S3FS = require('s3fs'),
s3fsImpl = new S3FS('mybucket-BrentsTest', {
accessKeyId: 'XXXXXXXXXXXXX',
secretAccessKey: 'XXXXXXXXXXXX'
});
var multiparty = require('connect-multiparty'),
multipartyMiddleware = multiparty();
// Create our bucket if it doesn't exist
router.get('/unlink/facebook', function(req, res){
var user = req.user;
user.facebook.token = null;
user.save(function(err){
if(err)
throw err;
if(!hasActiveLink(user))
res.redirect('/auth/logout');