Print an Integer Entered by the User : C Program

Computer Science » C Program » Print an Integer Entered by the User

Program :

#include <stdio.h>
 
int main()
{
    int number;
 
    printf("Enter an integer : ");
 
    scanf("%d", &number);
 
    printf("nInteger entered by you : %d", number);
    return 0;
}

Output :

Enter an integer : 121
Integer entered by you : 121
Subject Name : Computer Science
Exam Name : IIT GATE, UPSC ESE, RRB, SSC, DMRC, NMRC, BSNL, DRDO, ISRO, BARC, NIELIT
Posts Name : Assistant Engineer, Management Trainee, Junior Engineer, Technical Assistant
Computer Science Books

GATE 2023 Total InfoENGG DIPLOMAUGC NET Total Info
IES 2023 Total InfoPSUs 2022 Total InfoCSIR UGC NET Total Info
JAM 2023 Total InfoM TECH 2023 Total InfoRAILWAY 2022 Total Info

Related Posts

  • Reverse a Given Number : C ProgramComputer Science » C Program » Reverse a Given Number  Program : [php]#include<stdio.h> int main() { int num, rem, rev = 0; printf("nEnter any number to be reversed : "); scanf("%d", &num); while (num >= 1) { rem = num % 10; rev = rev * 10 + rem; num = num / 10; } printf("nReversed Number : %d", rev); return (0); }[/php] Output : [php]Enter any number to be reversed : 123 Reversed Number : 321[/php]
    Tags: program, computer, science, output, programs
  • C Program ExamplesComputer Science » C Program » C Program Examples "How to print hello, world! using c program ? How to find area of a circle using c program ? How to find smallest element in an array using c program ? You all must have this kind of questions in your mind. Below article will solve this puzzle of yours. Just take a look.”  - Here we have listed all the programs in C programming language, categorised under different progamming concepts like Basic, Area, Mathematical, Number, Array etc. Check the respective category to view all the programs under that category. C Programs - Basic C Programs C Programs - Number Programs C Programs - Area Programs C Programs - Mathematical Programs C Programs - Array Programs C Programs - Electrical Programs C Programs - Pyramid Programs
    Tags: programs, program, computer, science
  • Even Number Pyramid : C ProgramComputer Science » C Program » Even Number Pyramid Program : [php]#include&lt;stdio.h&gt; int main() { int i, j, num = 2; for (i = 0; i &lt; 4; i++) { num = 2; for (j = 0; j &lt;= i; j++) { printf(&quot;%dt&quot;, num); num = num + 2; } printf(&quot;n&quot;); } return (0); }[/php] Output : [php]2 2 4 2 4 6 2 4 6 8 [/php]
    Tags: program, computer, science, output, programs
  • Inverted Pyramid : C ProgramComputer Science » C Program » Inverted Pyramid  Program : [php]#include<stdio.h> int main() { int i, j; char ch = '*'; for (i = 4; i >= 0; i--) { printf("n"); for (j = 0; j < i; j++) printf("%c", ch); } return(0); }[/php] Output : [php]**** *** ** *[/php]
    Tags: program, computer, science, output, programs
  • Find sum of Two Integer Numbers : C ProgramComputer Science » C Program » Find sum of Two Integer Numbers Program : [php]#include<stdio.h> int main() { int a, b, sum; printf("Enter the two numbers : "); scanf("%d %d", &a, &b); sum = a + b; printf("nSum of %d and %d is : %d", a,b,sum); return(0); }[/php] Output : [php]Enter the two numbers : 2 4 Sum of 2 and 4 is : 6[/php]
    Tags: program, integer, computer, science, output, programs

LEAVE A REPLY

Please enter your comment!
Please enter your name here