Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

What is the difference between = and == in C?

Answer Posted / k.s. karthick prabu

= is the assigment operator

=is used to copy
ex:
a=5 means, copy just that value for 'a'.
== is comparision operator
ex:

#include<stdio.h>
void main()
{
int a;
scanf("%d",&a);
if(a==5)
printf("welcome");
else
printf("if the is not equal to 5");
}

Is This Answer Correct ?    37 Yes 7 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

A company pays its salespeople on a commission basis. The salespeople receive $200 per week plus 9 percent of their gross sales for that week. For example, a saleperson who sells $5000 worth of merchandise in a week receives $200 plus 9 percent of $5000, or a total of $650. You have been supplied with a list of items sold by each salesperson. The values of these items are as follows: Item Value A 239.99 B 129.75 C 99.95 D 350.89 Write a program that inputs one salesperson's items sold in a week (how many of item A? of item B? etc.) and calculates and displays that salesperson's earnings for that week.

3839


Define the process of handling in case of destructor failure?

994


what is the use of void main() in C++ language?

1062


What is ios in c++?

1159


What do c++ programmers do?

1012


Why is c++ not purely object oriented?

962


What do manipulators do?

962


What is helper in c++?

1036


Can we specify variable field width in a scanf() format string? If possible how?

1152


Differentiate between a constructor and a destructor in c++.

968


How would you find out if a linked-list is a cycle or not?

957


What is the difference between function overloading and operator overloading?

1033


What is endl c++?

1034


What is the default width for ouputting a long integer using the insertion operator?

1174


What are the two types of comments?

940