Skip to content

Instantly share code, notes, and snippets.

View thiagozs's full-sized avatar
:octocat:
Have a nice day

Thiago Zilli Sarmento thiagozs

:octocat:
Have a nice day
View GitHub Profile
@thiagozs
thiagozs / plusMinus.go
Created August 19, 2022 21:53
HackerRank plusMinus
package main
import (
"bufio"
"fmt"
"io"
"os"
"strconv"
"strings"
)
@thiagozs
thiagozs / birthdayCakeCandles.go
Created August 19, 2022 21:36
HackerRank birthdayCakeCandles
package main
import (
"bufio"
"fmt"
"io"
"os"
"strconv"
"strings"
"sort"
@thiagozs
thiagozs / miniMaxSum.go
Last active August 19, 2022 21:26
HackerRank miniMaxSum
package main
import (
"bufio"
"fmt"
"io"
"os"
"strconv"
"strings"
"sort"
@thiagozs
thiagozs / staircase.go
Created August 19, 2022 20:33
HackerRank staircase
package main
import (
"bufio"
"fmt"
"io"
"os"
"strconv"
"strings"
)
@thiagozs
thiagozs / clean-code-structure.md
Created April 14, 2022 18:01
Clean Code Golang

Clean code structure in golang

by Resotto

  • Good example of Go with Clean Architecture.
  • All kinds of Gophers (newbie to professional).

Package Structure

@thiagozs
thiagozs / cron.go
Created March 30, 2022 14:07
Golang cronx test integration
package main
import (
"context"
"fmt"
"os"
"os/signal"
"github.com/adhocore/gronx/pkg/tasker"
)
@thiagozs
thiagozs / docker_arg_env.md
Created March 2, 2022 12:48
docker arg env and .env complete guide

Docker ARG, ENV and .env - a Complete Guide

Error: Docker image build failed.

Building Docker images and configuring your dockerized apps doesn’t have to be a try-fail-repeat Google extravaganza. This article will help you work with Docker ARG, ENV, env_file and .env files with confidence.

The only prerequisite: make sure that you’re comfortable with the basics of Docker.

@thiagozs
thiagozs / validates_phone.go
Created February 8, 2022 19:52
Validation phone numbers
package main
import (
"fmt"
"regexp"
"github.com/nyaruka/phonenumbers"
)
func main() {
@thiagozs
thiagozs / checkstruct.go
Last active January 28, 2022 17:04
check struct and values
package main
import (
"fmt"
"github.com/google/go-cmp/cmp"
)
type Model struct {
A int
@thiagozs
thiagozs / jsonraw.go
Created December 8, 2021 21:02
Json.RawMessage tests and pocs
package main
import (
"encoding/json"
"fmt"
"strconv"
"strings"
"github.com/shopspring/decimal"
//"github.com/shopspring/decimal"