Golang unicode.UpperCase Constant with Examples

Golang | unicode.UpperCase Constant: Here, we are going to learn about the UpperCase constant of the unicode package with its usages, syntax, and examples.
Submitted by IncludeHelp, on September 15, 2021

unicode.UpperCase Constant

The UpperCase constant is an inbuilt constant of the unicode package which is used to get the index into the delta arrays inside CaseRanges for case mapping. The value of the UpperCase constant is 0.

Syntax:

int unicode.UpperCase

Parameter(s):

  • None

Return Value:

The return type of the unicode.UpperCase constant is an int, it returns the index into the delta arrays inside CaseRanges for case mapping.

Example:

// Golang program to demonstrate the
// example of unicode.UpperCase constant

package main

import (
	"fmt"
	"unicode"
)

func main() {
	fmt.Printf("Value of unicode.UpperCase: %d\n",
		unicode.UpperCase)
	fmt.Printf("Type of unicode.UpperCase: %T\n",
		unicode.UpperCase)
}

Output:

Value of unicode.UpperCase: 0
Type of unicode.UpperCase: int

Golang unicode Package »




Comments and Discussions!

Load comments ↻





Copyright © 2024 www.includehelp.com. All rights reserved.