Write a Go program to print the right triangle pattern of consecutive row numbers using for loop.
package main import "fmt" func main() { var i, j, row, val int fmt.Print("Enter Right Triangle of Consecutive Row Pattern Rows = ") fmt.Scanln(&row) fmt.Println("Right Triangle of Consecutive Row Numbers Pattern") for i = 1; i <= row; i++ { val = i for j = 1; j <= i; j++ { fmt.Printf("%d ", val) val = val + row - j } fmt.Println() } }