Skip to content

Instantly share code, notes, and snippets.

View scrouthtv's full-sized avatar
😃

scrouthtv

😃
View GitHub Profile
@scrouthtv
scrouthtv / custom.css
Created December 10, 2022 23:47
Add breathing effect to tabliss background image
.image {
animation-name: example;
animation-duration: 40s;
animation-iteration-count: infinite;
animation-direction: alternate;
animation-timing-function: ease-in-out;
}
@keyframes example {
@scrouthtv
scrouthtv / index.html
Last active February 20, 2022 10:05
Example website using ajax
<!DOCTYPE html>
<html>
<head>
<link rel="stylesheet" href="style.css" />
<script>
setInterval(function() {
var xhttp = new XMLHttpRequest(); // https://w3schools.com/xml/xml_http.asp
xhttp.onreadystatechange = function() {
if (this.readyState == 4 && this.status == 200) {
@scrouthtv
scrouthtv / Arch-aarch-qemu
Created October 15, 2021 16:10
Creating an aarch64 VM for qemuhost, with Arch Linux guest
/*
* This document is provided to the public domain under the
* terms of the WTFPL license.
*/
This is
This is a combination of
- [How to boot Arch Linux ARM in QEMU (patched for M1)](https://gist.github.com/thalamus/561d028ff5b66310fac1224f3d023c12) - thanks to Avatar
Will Tisdale
@scrouthtv
scrouthtv / append_test.go
Created October 13, 2021 09:24
Go append vs prepend
package app
import "testing"
import "math/rand"
func BenchmarkAppend(b *testing.B) {
arr := make([]int, 5)
for i, _ := range arr {
arr[i] = rand.Int()
}
@scrouthtv
scrouthtv / HPL.md
Created September 15, 2021 19:53
How to build HPL for your local PC (Arch edition)
@scrouthtv
scrouthtv / wordsearcher.go
Created December 20, 2020 12:10
Search a word based on given letters in any orders
package main
import "fmt"
import "bufio"
import "os"
import "sort"
import "strings"
func doSort(rs []rune) {
sort.SliceStable(rs, func(i int, j int) bool {
@scrouthtv
scrouthtv / WebInteraction.java
Created July 30, 2018 12:07
Basic post http request for java
package main;
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.io.OutputStreamWriter;
import java.net.HttpURLConnection;
import java.net.URL;
public class WebInteraction {