Menu
Question Index
...

Write a program to print numbers in reverse order from the given input number till 1. Every number should be on a separate line. Use System.out.println or System.out.print for printing.

Input Printed Output
6 6
5
4
3
2
1
10 10
9
8
7
6
5
4
3
2
1



class PrintNumbersInReverse
{
    public static void main(String s[])
    {
        printNumbersInReverse(7);

    }


    public static void printNumbersInReverse(int input)
    {
    }

}

Doubts

Problems

Topic: for Loop In Java

Read this topic
Take test on this topic

0
Wrong
Score more than 2 points

© meritcampus 2019

All Rights Reserved.

Open In App