class Power
{
public static void main(String args[])
{
int n1,n2,i,power=1;
n1=(int)(Math.random()*10);
n2=(int)(Math.random()*10);
System.out.println("First generated no. is="+n1);
System.out.println("Second generated no. is="+n2);
for(i=1;i<n2;n2++)
{
power*=n1;
System.out.println("Power of number is:"+power);
}
}
}
Popular Posts
-
<html> <head> <Title>Table Assignment</Title> <style type="text/css"> ...
-
<html> <head> <Title>Table Assignment</Title> <style type="text/css"> ...
-
class Gcd { public static void main(String args[]) { int n1=(int)(Math.random()*100); int n2=(int)(Math.random()*100); Syst...
-
rs.lastindex(); int totalRow=rs.getRow(); System.out.println("Number of rows in resultset is "+totalRow);
-
class Power { public static void main(String args[]) { int n1,n2,i,power=1; n1=(int)(Math.random()*10); ...
No comments:
Post a Comment