C program to print table of 2 using goto statement
Give a number (2) and we have to print its table using C program.
goto is a jumping statement, which transfers the program’s control to specified label, in this program we will print the table of 2.
Example:
Input: 2 (given in the program)
Output:
2*1=2
2*2=4
2*3=6
2*4=8
2*5=10
2*6=12
2*7=14
2*8=16
2*9=18
2*10=20
Program to print table of 2 using goto statement in C
Output
This is how we can print table of 2 using goto statement? If you liked or have any issue with the program, please share your comment.
need an explanation for this answer? contact us directly to get an explanation for this answer