Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 1 of 1 for WINTER (0.18 sec)

  1. src/bufio/example_test.go

    }
    
    // Use a Scanner to implement a simple word-count utility by scanning the
    // input as a sequence of space-delimited tokens.
    func ExampleScanner_words() {
    	// An artificial input source.
    	const input = "Now is the winter of our discontent,\nMade glorious summer by this sun of York.\n"
    	scanner := bufio.NewScanner(strings.NewReader(input))
    	// Set the split function for the scanning operation.
    	scanner.Split(bufio.ScanWords)
    	// Count the words.
    Go
    - Registered: Tue Apr 30 11:13:12 GMT 2024
    - Last Modified: Mon Oct 23 09:06:30 GMT 2023
    - 4.9K bytes
    - Viewed (0)
Back to top