Skip to content

Instantly share code, notes, and snippets.

View raszia's full-sized avatar
🏠
Working from home

Rasool Ziafaty raszia

🏠
Working from home
View GitHub Profile
@raszia
raszia / multicast.go
Last active March 9, 2023 07:33
multicast with golang
package main
import (
"fmt"
"net"
"golang.org/x/net/ipv4"
)
func main() {
@raszia
raszia / pygo.go
Last active November 20, 2023 08:31
Python script inside Golang
package main
/*
#cgo CFLAGS: -I/usr/include/python3.8
#cgo LDFLAGS: -lpython3.8
#include <Python.h>
*/
import "C"
import (
@raszia
raszia / cardGenerator.py
Created March 28, 2020 07:00
Random shomare-cart generator
#!/usr/bin/python3
import random
def card_generator():
while True:
rand_list = [random.randint(0, 9) for iter in range(16)]
rand_list[0] = random.randint(4, 6)
numbers_add = 0
#print (rand_list)
@michaljemala
michaljemala / tls-client.go
Last active May 31, 2024 02:51
SSL Client Authentication Golang sample
package main
import (
"crypto/tls"
"crypto/x509"
"flag"
"io/ioutil"
"log"
"net/http"
)
@vderyagin
vderyagin / priority_queue.go
Last active November 27, 2022 18:50
Priority Queue data structure implementation in Go
package priority_queue
import "errors"
type Elem struct {
Score int
Data interface{}
}
type priorityQueue struct {