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
package main | |
import "fmt" | |
// Node ... | |
type Node struct { | |
Data interface{} | |
Left *Node | |
Right *Node | |
} |
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
package main | |
import "fmt" | |
// Queue ... | |
type Queue struct { | |
Head int | |
Tail int | |
Size int | |
Items []interface{} |
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
package main | |
import "fmt" | |
// Stack ... | |
type Stack struct { | |
Items []int64 | |
Top int | |
} |
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
# -*- coding: utf-8 -*- | |
""" | |
Upload folder to Google Drive | |
""" | |
# Enable Python3 compatibility | |
from __future__ import (unicode_literals, absolute_import, print_function, | |
division) |
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
<?php | |
namespace App\Http\Controllers; | |
use App\Locations; | |
use App\History; | |
use Illuminate\Http\Request; | |
use App\Http\Controllers\Controller; | |
use Illuminate\Http\Response; | |
use Illuminate\Support\Facades\DB; | |
use DateTime; | |
use DateInterval; |
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
$.get( "example.php", function(response) { | |
console.log(response.data) | |
alert( "success" ); | |
}) | |
.done(function() { | |
alert( "second success" ); | |
}) | |
.fail(function() { | |
alert( "error" ); | |
}) |
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
.row { | |
display: block; | |
padding-right: 35px; | |
padding-left: 35px; | |
clear:both; | |
} | |
/* For mobile phones: */ | |
[class*="col-"] { | |
width: 100%; | |
} |
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 axios from 'axios' | |
import store from '../store' | |
import qs from 'qs' | |
export const http = axios.create({ | |
baseURL: 'http://localhost:8000/api/', | |
header: { | |
'Content-Type': 'application/x-www-form-urlencoded' | |
} | |
}) |
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
<?php | |
namespace App\Http\Middleware; | |
use Closure; | |
class CorsMiddleware { | |
/** | |
* Handle an incoming request. | |
* | |
* @param \Illuminate\Http\Request $request |