Thursday 18 July 2013


#include "stdafx.h"
#include "conio.h"
#include "iostream"
#include "stdio.h"

using namespace std;

int _tmain(int argc, _TCHAR* argv[])
{
int n,len,t; // length , table
int c;
cout<<"enter a number whose table is to be calculated"<<endl;
cin>>n;
cout<<"enter length of table"<<endl;
cin>>len;
c=1;
while(c<=len)
{   
t=n*c;
cout<<n<<"*"<<c<<"="<<t<<endl;
c++;
}
getch();

}

0 comments :

Post a Comment