Multiplication Table Up to a range (entered by the user)


SUBMITTED BY: kaushal1981

DATE: Feb. 23, 2017, 7:11 a.m.

FORMAT: Text only

SIZE: 289 Bytes

HITS: 1204

  1. #include <stdio.h>
  2. int main()
  3. {
  4. int n, i, range;
  5. printf("Enter an integer: ");
  6. scanf("%d",&n);
  7. printf("Enter the range: ");
  8. scanf("%d", &range);
  9. for(i=1; i <= range; ++i)
  10. {
  11. printf("%d * %d = %d \n", n, i, n*i);
  12. }
  13. return 0;
  14. }

comments powered by Disqus