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
<project xmlns="http://maven.apache.org/POM/4.0.0" | |
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | |
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> | |
<modelVersion>4.0.0</modelVersion> | |
<groupId>io.github.spriithy</groupId> | |
<artifactId>project-name</artifactId> | |
<version>0.0.1-SNAPSHOT</version> | |
<dependencies> | |
<!-- https://mvnrepository.com/artifact/org.apache.commons/commons-lang3 --> | |
<dependency> |
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 "tvm.c" | |
int main(void) | |
{ | |
int code[] = { | |
Const, | |
-5564, | |
Const, | |
184841, | |
Add, |
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
module Lex ( | |
Token(..), | |
tokKind, | |
tokText, | |
tokPos, | |
Kind(..), | |
doLex, | |
) where | |
import Data.Char |
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
export default class Client { | |
constructor() { | |
this.local = window.location.href.indexOf("file://") > -1 || window.location.href.indexOf("localhost") > -1; | |
this.twitchKey = this.local ? "miocs45t65k5y2ym8vtfq56lpofbocv" : "74q6uco0vgklzwgehthw3fbyfif54er"; | |
this.racers = []; | |
this.websocket = null; | |
this.wsUri = "ws://perso.mog-creations.com:43042/"; |
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
{ | |
"workbench.sideBar.location": "right", | |
"files.associations": { | |
"*.h": "c", | |
"*.c": "c" | |
}, | |
"editor.formatOnSave": true, | |
"editor.rulers": [ | |
80 | |
], |
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
func IsPerfectSquare(n int64) bool { | |
h := n & 0xF; // last hexadecimal "digit" | |
if h > 9 { | |
return false | |
} | |
// Take advantage of Boolean short-circuit evaluation | |
if ( h != 2 && h != 3 && h != 5 && h != 6 && h != 7 && h != 8 ) { | |
t := (int64) (math.Floor(math.Sqrt((float64)(n)) + 0.5 )) | |
return t * t == n | |
} |
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" | |
func main () { | |
fmt.Println("-= Stack Demo =-") | |
s := Stack() | |
s.Push(Int, 0) | |
s.Push(Int, 1) | |
s.Push(Int, 2) |
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 time | |
it = 0 | |
L = [] | |
i = 1 | |
mi = 0 | |
mv = 1 | |
dt = time.time() |
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
public class GUIDFactory { | |
private static final String chars = "0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ"; | |
private static final int charsCount = chars.length(); | |
/** | |
* Generates a random GUID. Example : | |
* | |
* <pre> | |
* 13219ec0-3a81-44c5-a300-de14b7d0235f | |
* </pre> |