Ghislain_Mike

Multiplication table

Feb 8th, 2019
109
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C 0.27 KB | None | 0 0
  1. #include <stdio.h>
  2. #include <stdlib.h>
  3.  
  4. int main() {
  5.   int NUMBER, ANSWER, i;
  6.  
  7.   printf("Enter a number = ");
  8.   scanf("%d", &NUMBER);
  9.  
  10.   for (i = 1; i < 11; i++) {
  11.     ANSWER = NUMBER * i;
  12.  
  13.     printf("%d * %d = %d\n", NUMBER, i, ANSWER);
  14.   }
  15.  
  16.   return 0;
  17. }
Advertisement
Add Comment
Please, Sign In to add comment