ToTitle in Go

Posted by GoDoc
Public (Editable by Users)

ToTitle maps the rune to title case.

Go
Edit
package main

import (
	"fmt"
	"unicode"
)

func main() {
	const ucG = 'g'
	fmt.Printf("%#U\n", unicode.ToTitle(ucG))
}