#include<stdio.h> int main() { int num1,num2,num3; printf("\nEnter value of num1,num2,num3:"); scanf("%d %d %d", &num1, &num2 ,&num3); if((num1>num2)&&(num1>num3)){ printf("The greatest number is num1\n"); } else if((num2>num3)&&(num2>num1)){ printf("The greatest number is num2\n"); }else{ printf("The greatest number is num3\n"); } return 0; } after that when you run this code into your Vs code terminal, you have to give some input to your program then press "Enter" and you will see the output in your terminal.
#include<stdio.h> int main(int argc, char *argv[]) { int a, b; printf("Enter number a\n"); scanf("%d", &a); printf("Enter number b\n"); scanf("%d", &b); printf("The sum is %d\n", a+b); return 0; } Now give two integers as user input and press "Enter" and check the results. If you have any doubt comment down below.
Hi guys the problem I am going to discuss in this blog is about some problem that you may face while doing C programme in your VS code. There are various methods to install VS code and MinGW(C compiler) but when you use them to run a code it may show you some error in output or in VS code terminal. But if you think your installation process is wrong, wait that may be not the reason, it's because of your system's anti virus that is blocking your VS code to get access of your MinGW's bin folder. This problem mostly seen when you buy a new Laptop or PC & they give you a trial of anti virus software (McAfee). Solution : All you need to do is when you gonna run a programme in your system simply 1>Open your McAfee anti virus application 2>Now find the settings option then click on it and then click on "Real Time Scanning" 3>Now last step is click on the "Turn Off" button and turn it off as long as you want. With these simple steps you can e...
Comments
Post a Comment