Go 1.22 now ships with an HTTP server multiplexer, so there is no longer a need to include routing libraries like httprouter or chi.
package main
Go 1.22 now ships with an HTTP server multiplexer, so there is no longer a need to include routing libraries like httprouter or chi.
package main
int calculate(int bottom, int top)
{
if (top > bottom)
package utils | |
func GetKeys[K comparable, V any](m map[K]V) []K { | |
keys := make([]K, 0, len(m)) | |
for k := range m { | |
keys = append(keys, k) | |
} | |
return keys | |
} |
set termguicolors | |
" Set compatibility to Vim only. | |
" be vim no vi. | |
set nocompatible | |
" Disable the default Vim startup message. | |
set shortmess+=I | |
" Helps force plug-ins to load correctly when it is turned back on below. |
#!/usr/bin/env bash | |
# find filename on https://go.dev/dl/ | |
GO_FILE_NAME="go1.19.3.darwin-arm64.tar.gz" | |
# usage: | |
# chmod u+x install_go.sh | |
# sudo ./install_go.sh | |
mkdir /tmp/downloads |
Securing something is about restricting access or access control. To control access, you need to differentiate those who have access and those who don't. This inherently requires you to be able to identify the user (authentication). To identify users, you need an identity provider, a service that stores and provides user information aka identity. Once you can identify users, you need to associate a user/s to a permissions list or ruleset.
The Cognito User Pool is an identity provider, and the Cognito Identity Pool federates identities from multiple identity providers and then applys a ruleset via IAM roles.
An AWS account has resources and users. It also has an account-id
.
By default a root user is created, and this user has complete and unrestricted access to all resources in your AWS account.
AWS IAM is used to manage users (identity) and resource access (access management) on an AWS account.
All AWS resources have a unique identifier known as an ARN.
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta charset="UTF-8" /> | |
<meta name="viewport" content="width=device-width, initial-scale=1.0" /> | |
<title>center a div</title> | |
<style> | |
.container { | |
height: 100vh; | |
display: flex; |
package main | |
import "fmt" | |
type Node[T any] struct { | |
Next *Node[T] | |
Value T | |
} | |
type LinkedList[T any] struct { |