awesome-go/impl/files-manipulation/14-QuickWriteToFile.go

19 lines
206 B
Go
Raw Normal View History

package main
import (
2024-01-20 08:55:19 +00:00
"os"
"log"
)
func main() {
/*
Hızlıca Dosya Yazma (Quick Write to File)
*/
2024-01-20 08:55:19 +00:00
err := os.WriteFile("demo.txt", []byte("Hi!\n"), 0666)
if err != nil {
log.Fatal(err)
}
}