HOME/Articles/

Golang golang-reader (snippet)

Article Outline

Go programming example 'golang-reader'

golang-reader

Golang beginners example: golang-reader

package main

import (
    "./packages/"
    "bufio"
    "log"
)

func main() {
    M := foobar.NewReader()

    bytes := make([]byte, 255)

    bufio.NewReader(M).Read(bytes)

    log.Printf("%s", bytes)
}