Write a shell script to print all natural numbers in reverse (from n to 1).



Write a shell script to print all natural numbers

 in reverse 

(from n to 1).




Program =




#!/bin/bash

echo " UTSAV Gohel  - 91900104011"

 

echo "Enter the Upper limit = "

read n

 

  echo " Natural numbers in reverse order are  ..."

for ((i=n; i>=1; i--))

do

  echo "$i"

done



Output :-