Demo entry 6338357

kk

   

Submitted by anonymous on Dec 12, 2016 at 21:24
Language: Go. Code size: 365 Bytes.

ackage main

import (
	"fmt"
	"math/rand"
	"strconv"
	"sync"
	"time"
)

var floats = []float64{100.00, 200.00, 300.00}
var sleeps = []int{1, 2, 3, 4, 5}

var wg sync.WaitGroup
var balance = &currency{100.00, "USD"}
var am = 0.00

type currency struct {
	amount float64
	code   string
}

func (c *currency) Add(i float64) {
	c.amount += i
}

This snippet took 0.00 seconds to highlight.

Back to the Entry List or Home.

Delete this entry (admin only).