Friday, 18 April 2014

Multiplication Table using Java

Simple Multiplication Table in Java

Java Code to print Multiplication Table

//A small java program to print the Multiplication Table

import java.util.Scanner;
class MultiplicationTable
   public static void main(String args[])
      int n, c;
      System.out.println("Enter an integer to print it's multiplication table");
      Scanner in = new Scanner(;
      n = in.nextInt();
      System.out.println("Multiplication table of "+n+" is :-");
      for ( c = 1 ; c <= 10 ; c++ )
         System.out.println(n+"*"+c+" = "+(n*c));


        The output of the program is as shown below

Mutiplication Table


  1. -------------------------------------------------------------------------------------------------------------------------------
    Sell to earn 30% commission per sale. (PARTENERSHIP PROGRAMME)

    You don,t have interest to buy this software, you sell this software
    also on ur website
    Per software u earn 30% commission on each sale
    all promotion material provided to after sing up process on site.
    links, banner, flash banner, sign up form and login form also provided
    here for ur website.
    visit to sing up (FREE TO JOIN)

  2. nice information