Skip to content

Instantly share code, notes, and snippets.

View aarjan's full-sized avatar
🎯
Focusing

Aarjan Baskota aarjan

🎯
Focusing
  • Zegal
View GitHub Profile
@aarjan
aarjan / main.dart
Created November 8, 2022 10:41
Sunflower example
import 'package:flutter/material.dart';
void main() {
runApp(HomeScreen());
}
class CardClipper extends CustomClipper<Path> {
@override
Path getClip(Size size) {
Path path = Path();
@aarjan
aarjan / contracts...Token.sol
Created March 5, 2022 09:36
Created using remix-ide: Realtime Ethereum Contract Compiler and Runtime. Load this file by pasting this gists URL or ID at https://remix.ethereum.org/#version=soljson-v0.8.7+commit.e28d00a7.js&optimize=false&runs=200&gist=
// SPDX-License-Identifier: MIT
pragma solidity >=0.8;
interface IBEP20 {
/**
* @dev Returns the amount of tokens in existence.
*/
function totalSupply() external view returns (uint256);
/**
@aarjan
aarjan / Dockerfile
Last active August 28, 2018 10:47
A simple Dockerfile for a Go application
# Build stage
# Install tools required
FROM golang:1.10.2 AS build
RUN go get -u github.com/golang/dep/cmd/dep
# List project dependencies with Gopkg.toml and Gopkg.lock
# These layers are only re-built when Gopkg files are updated
COPY Gopkg.lock Gopkg.toml /go/src/projectpath/
WORKDIR /go/src/projectpath/
@aarjan
aarjan / main.go
Last active August 22, 2018 11:11
A concurrent worker thread pool model to handle POST request
package main
import (
"encoding/json"
"fmt"
"log"
"net/http"
"time"
)
@aarjan
aarjan / main.go
Last active August 21, 2018 11:18
Simple concurrent worker model
package main
import (
"encoding/json"
"io/ioutil"
"log"
"net/http"
"time"
)