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
| package main | |
| import ( | |
| "database/sql" | |
| "log" | |
| "github.com/google/uuid" | |
| _ "github.com/mattn/go-sqlite3" | |
| ) |
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
| package main | |
| import ( | |
| "database/sql" | |
| "encoding/binary" | |
| "fmt" | |
| "sort" | |
| "strings" | |
| "testing" |
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
| pacakge main | |
| import ( | |
| "math/rand" | |
| "unicode" | |
| ) | |
| func randomString(n int) string { | |
| res := make([]rune, n) |
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
| <!DOCTYPE html> | |
| <html> | |
| <head> | |
| <meta charset="UTF-8" /> | |
| <meta name="viewport" content="width=device-width" /> | |
| <title>Index</title> | |
| </head> | |
| <style type="text/css" media="screen"> | |
| input.noarrows::-webkit-outer-spin-button, | |
| input.noarrows::-webkit-inner-spin-button { |
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
| package main | |
| import ( | |
| "time" | |
| "github.com/google/uuid" | |
| ) | |
| type ( | |
| SystemDeviceInfo struct { |
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
| package main | |
| import "log" | |
| type CounterMessage int | |
| func main() { | |
| var a1 *Actor | |
| var a2 *Actor |
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
| package stream | |
| import ( | |
| "context" | |
| "errors" | |
| "sync" | |
| ) | |
| type CancelableMessage[T any] struct { | |
| ctx context.Context |
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
| // go version go1.20.7 linux/amd64 | |
| package main | |
| import ( | |
| "context" | |
| "database/sql" | |
| "errors" | |
| "log" | |
| "sync" | |
| "time" |
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
| package matview | |
| // I have a go data structure that stores a buffer of events. The events are | |
| // tuples of (K, V, OP) where K is a unique identifier for the event, V is other | |
| // data associated with the event, and OP is an operation that is either PUT or | |
| // DEL. For an event with a "PUT" OP, the event will be appended to the buffer | |
| // of events, if the event's K exists then the value will be overwritten. For an | |
| // event with a "DEL" OP, the event found and removed from the buffer. Consumers | |
| // of this data structure subscribe and get the full state of the events stored | |
| // and all subsequent events. |
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
| import { component$ } from "@builder.io/qwik"; | |
| import { | |
| type DocumentHead, | |
| routeLoader$, | |
| routeAction$, | |
| zod$, | |
| z, | |
| Form, | |
| } from "@builder.io/qwik-city"; | |
| import styles from "./todolist.module.css"; |