rainwater

command
v0.0.0-...-fe72480 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 16, 2018 License: MIT Imports: 2 Imported by: 0

README

rainwater

The problem is basically calculate the rain water accumulater in the valleys give that a topography is represented in an array. 0 means sea level.

For example:

[ 3, 2, 2, 5, 2, 1, 7 ]

In this case:

+0 +1 +1 +0 +3 +4 +0 = 9 [ 3, 2, 2, 5, 2, 1, 7 ]

Solutions are in Go:

  • rainwater.go - Solution in go. Run with: go run rainwater.go

Documentation

The Go Gopher

There is no documentation for this package.

Source Files

  • rainwater.go

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL